/* Exact PhotoFirst.dc.html row geometry, scoped to dashboard B. */
/* Retain controller inputs while removing the redundant upper dashboard panel. */
.dashboard-controls { display: none !important; }
.pf-dashboard { color: #26231f; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; }
.pf-toolbar { display: flex; align-items: center; gap: 14px; padding: 14px 4px; }
.pf-toolbar input { flex: 1; min-width: 120px; padding: 9px 12px; border: 1px solid #e7e2d8; border-radius: 7px; }
.pf-toolbar a { color: #686359; font-size: 12px; white-space: nowrap; }
.pf-toolbar button, .pf-collapse { border: 1px solid #e7e2d8; border-radius: 6px; background: #fff; padding: 8px 12px; cursor: pointer; }
.pf-row, .pf-row *, .pf-dialog, .pf-dialog * { box-sizing: border-box; }
.pf-body :where(button) { appearance: none; border: 0; background: transparent; font: inherit; line-height: normal; text-align: left; margin: 0; padding: 0; min-height: 0; min-width: 0; box-shadow: none; cursor: pointer; }
.pf-body button:focus-visible, .pf-dialog button:focus-visible { outline: 2px solid #47606f; outline-offset: -2px; }

  .pf-serif { font-family: 'Source Serif 4', Georgia, serif; }
  .pf-row {
    line-height: normal;
    width: 1649px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #ffffff;
    border: 1px solid #e7e2d8;
    border-radius: 10px;
    color: #26231f;
    overflow: hidden;
    transition: background-color .12s ease, border-color .12s ease, box-shadow .12s ease;
  }
  /* Row-wide hover highlight so the row under the pointer is unmistakable (all rows, finished or not). */
  .pf-row:hover, .pf-row:focus-within {
    background: #eef4fd;
    border-color: #9ec0f5;
    box-shadow: 0 0 0 2px rgba(1, 79, 242, .14), 0 3px 10px rgba(38, 35, 31, .10);
  }
  .pf-body { display: flex; align-items: center; }

  .pf-photostrip { display: flex; gap: 8px; padding: 9px; flex-shrink: 0; }
  .pf-photo {
    width: 68px; height: 68px; border-radius: 8px; border: none; padding: 0; margin: 0;
    cursor: pointer; position: relative; display: flex; align-items: center; justify-content: center;
    background: #f4f1e9; box-shadow: 0 1px 2px rgba(38,35,31,.10);
  }
  .pf-photo .pf-placeholder-icon { width: 22px; height: 22px; color: #8ba8bd; }
  .pf-photo.pf-has-photo { background: linear-gradient(135deg,#8a7a5c,#c9b896 55%,#dcd2c2); }
  .pf-photo .pf-badge {
    position: absolute; right: 4px; bottom: 4px; width: 22px; height: 22px; border-radius: 50%;
    background: rgba(38,35,31,.72); display: flex; align-items: center; justify-content: center;
  }
  .pf-photo .pf-badge svg { width: 12px; height: 12px; color: #fff; }

  .pf-date { width: 68px; height: 68px; flex-shrink: 0; }
  .pf-date-inner {
    width: 100%; height: 100%; border-radius: 8px; overflow: hidden;
    display: flex; flex-direction: column; box-shadow: 0 1px 2px rgba(38,35,31,.10);
  }
  .pf-date-band { background: #f1e8e2; color: #7b675b; font-size: 9px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; text-align: center; padding: 3px 0 2px; }
  .pf-date-body { flex: 1; background: #fdfaf7; display: flex; flex-direction: column; align-items: center; justify-content: center; }
  .pf-date-day { font-size: 24px; font-weight: 700; color: #7b675b; line-height: 1; }

  .pf-date.pf-inspection .pf-date-band { background: #eaf0f2; color: #62767d; }
  .pf-date.pf-inspection .pf-date-body { background: #fafcfc; }
  .pf-date.pf-inspection .pf-date-day { color: #62767d; }

  .pf-zone-tile { display: flex; align-items: center; padding: 9px 16px; border-left: 1px solid #f1ede2; flex-shrink: 0; }

  .pf-property { display: flex; flex-direction: column; justify-content: flex-start; gap: 0; padding: 0; border-left: 1px solid #f1ede2; flex-shrink: 0; width: 414px; }

  .pf-timeline { display: grid; grid-template-columns: repeat(8, minmax(0, 173fr)) minmax(0, 56fr); gap: 2px; height: 12px; margin: 1px 0; flex-shrink: 0; width: 100%; }
  .pf-body .pf-node { width: 100%; height: 12px; margin: 0; padding: 0 2px; line-height: 11px; border-radius: 2px; border: 1px solid #eeece6; background: #fbfaf8; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 500; color: #a39d92; }
  .pf-body .pf-node.pf-node-on,
  .pf-body .pf-timeline:has([data-pf-step="FIN"].pf-node-on) .pf-node:is([data-pf-step="CRR"], [data-pf-step="HLD"]) { background: #5488f4; border-color: #5488f4; color: #fff; } /* active files */
  /* Finished (subdued) rows: completed chips go neutral gray instead of blue. */
  .pf-row-subdued .pf-body .pf-node.pf-node-on,
  .pf-row-subdued .pf-body .pf-timeline:has([data-pf-step="FIN"].pf-node-on) .pf-node:is([data-pf-step="CRR"], [data-pf-step="HLD"]) { background: #999d9f; border-color: #999d9f; }

  .pf-address-line { display: flex; align-items: baseline; gap: 8px; }
  .pf-address-line .pf-address { font-size: 16px; font-weight: 700; white-space: nowrap; }
  .pf-badges { display: flex; gap: 5px; }
  /* Eyebrow tag chips: small uppercase, letter-spaced, hairline border, no fill. */
  .pf-badge { font-size: 9.5px; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; line-height: 1.2; color: #6f6a5e; background: transparent; border: 1px solid #e1dbcf; border-radius: 3px; padding: 3px 7px; }
  .pf-badge.dashboard-uad36-assist-badge { margin-left: 0; color: #4d2ca6; background: rgba(190, 172, 255, 0.5); border-color: rgba(124, 92, 224, 0.45); }


  .pf-zone { display: flex; align-items: center; gap: 6px; padding: 0 16px; border-left: 1px solid #f1ede2; height: 64px; flex-shrink: 0; }
  .pf-zone .pf-zone-label { font-size: 9px; text-transform: uppercase; color: #a89f8f; letter-spacing: .04em; display: block; }
  .pf-zone .pf-value { font-size: 12.5px; font-weight: 600; }

  .pf-notes { flex: 1; min-width: 0; }
  .pf-avatar { width: 21px; height: 21px; border-radius: 50%; background: #2f6f4e; color: #fff; font-size: 9px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
  .pf-notetxt { font-size: 12px; color: #4a453d; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .pf-notetxt b { color: #26231f; }


  .pf-zone-tile.pf-clickable { cursor: pointer; }
  .pf-zone-tile.pf-clickable:hover .pf-date-inner { box-shadow: 0 3px 10px rgba(38,35,31,.18); }


/* Integration with the existing dashboard; never rearrange the reference row. */
.pf-table-scroll { overflow-x: auto; width: 100%; }
/* The pinned control is the only visible bar; the list still accepts gestures. */
.pf-table-scroll:has(+ .pf-bottom-scroll) { scrollbar-width: none; }
.pf-table-scroll:has(+ .pf-bottom-scroll)::-webkit-scrollbar { display: none; }
/* Clip rounded corners without creating an ancestor scrollport that traps sticky. */
.container:has(.pf-dashboard), .reports-table:has(.pf-dashboard) { overflow: clip; }
.pf-bottom-scroll {
    position: sticky;
    bottom: 0;
    z-index: 5;
    width: 100%;
    height: 18px;
    overflow-x: scroll;
    overflow-y: hidden;
    background: #ece9e2;
    box-shadow: 0 -1px 3px #26231f20;
}
.pf-bottom-scroll[hidden] { display: none; }
.pf-bottom-scroll > div { height: 1px; }
/* Explicit styling keeps the draggable bar visible with macOS overlay scrollbars. */
.pf-bottom-scroll::-webkit-scrollbar { height: 16px; }
.pf-bottom-scroll::-webkit-scrollbar-track { background: #ece9e2; }
.pf-bottom-scroll::-webkit-scrollbar-thumb { background: #8b8983; border: 3px solid #ece9e2; border-radius: 8px; }
.pf-bottom-scroll::-webkit-scrollbar-thumb:hover { background: #62645f; }
.pf-bottom-scroll:focus-visible { outline: 2px solid #496c86; outline-offset: -2px; }
@media print { .pf-bottom-scroll { display: none !important; } }
#tableContent .pf-table { width: 1649px !important; min-width: 1649px !important; table-layout: fixed; border-collapse: separate; border-spacing: 0 6px; background: transparent; }
#tableContent .pf-table > tbody > tr > .pf-cell { width: 1649px !important; padding: 0 !important; border: 0; }
#tableContent .pf-cell > .pf-row { display: block !important; padding: 0 !important; margin: 0 !important; }
.pf-photo { flex-shrink: 0; overflow: hidden; }
.pf-photo > img { width: 100%; height: 100%; object-fit: cover; }
.pf-property { min-width: 0; height: 86px; }
.pf-address-line { min-width: 0; }
.pf-body .pf-address { cursor: pointer; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.pf-body .pf-address:hover, .pf-body .pf-address:focus-visible { text-decoration-line: underline; }
.pf-body .pf-address { color: #014ff2; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; font-size: 16px; font-weight: 600; line-height: normal; overflow: hidden; text-overflow: ellipsis; }
.pf-badges { flex-shrink: 0; }
.pf-body .pf-zone-tile { padding: 9px 16px; border-left: 1px solid #f1ede2; }
.pf-body .pf-notes { padding: 0 16px; border-left: 1px solid #f1ede2; }
.pf-body .pf-notes { min-width: 0; text-align: left; }
.pf-save-status:empty { display: none; }
.pf-dialog { margin: auto; width: 360px; max-width: calc(100vw - 32px); padding: 0; border: 0; border-radius: 14px; overflow: hidden; color: #26231f; background: #fff; box-shadow: 0 24px 60px rgba(38,35,31,.28); font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; }
.pf-dialog::backdrop { background: rgba(38,35,31,.45); }
.pf-modal-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 14px; }
.pf-modal-title { font-size: 15px; font-weight: 700; }
.pf-modal-x { width: 26px; height: 26px; border: 0; background: transparent; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #a89f8f; cursor: pointer; padding: 0; }
.pf-modal-x svg { width: 14px; height: 14px; }
.pf-modal-x:hover { background: #f4f1e9; color: #26231f; }
.pf-modal-body { border: 0; margin: 0; padding: 4px 20px 8px; display: flex; flex-direction: column; gap: 16px; }
.pf-modal-field { display: flex; flex-direction: column; gap: 6px; margin: 0; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: #a89f8f; min-width: 0; }
.pf-modal-field input, .pf-modal-field select { width: 100%; min-width: 0; height: auto; margin: 0; border: 1px solid #e7e2d8; border-radius: 8px; padding: 9px 11px; font-size: 14px; color: #26231f; font-family: inherit; font-weight: 400; background: #fbfaf7; }
.pf-modal-field input:focus, .pf-modal-field select:focus { outline: none; border-color: #47606f; background: #fff; }
.pf-modal-row2 { display: flex; gap: 12px; }
.pf-modal-row2 .pf-modal-field { flex: 1; }
.pf-dialog-actions { display: flex; justify-content: flex-end; gap: 8px; padding: 16px 20px 20px; border-top: 1px solid #f1ede2; margin-top: 4px; }
.pf-cancel, .pf-done { border: 0; border-radius: 8px; padding: 9px 16px; font-size: 13px; font-weight: 700; cursor: pointer; font-family: inherit; }
.pf-cancel { background: transparent; color: #6f6a5e; }
.pf-cancel:hover { background: #f4f1e9; }
.pf-done { background: #47606f; color: #fff; }
.pf-done:hover { background: #3a4f5c; }
.pf-dialog button:disabled { opacity: .6; cursor: wait; }
.pf-save-status { margin: 0; padding: 8px 20px; font-size: 12px; }
@media (max-width: 768px) {
    .pf-toolbar { flex-wrap: wrap; }
    .pf-toolbar strong { width: 100%; }
    #tableContent .pf-table, #tableContent .pf-table > tbody { display: table !important; width: 1649px !important; }
    #tableContent .pf-table > tbody { display: table-row-group !important; }
    #tableContent .pf-table > tbody > tr { display: table-row !important; }
    #tableContent .pf-table > tbody > tr > .pf-cell { display: table-cell !important; }
}

.pf-notetxt .dashboard-latest-note-preview__text { display: inline; color: inherit; font: inherit; white-space: inherit; }

.pf-modal-row2 .pf-time-field { flex: 1.6; }
.pf-time-picker { display: flex; gap: 3px; }
.pf-time-picker select { padding: 9px 3px; width: 0; flex: 1; }
.pf-time-picker select[data-pf-hour] { flex: 1.4; }
.pf-time-picker select:last-child { flex: 1.3; }

/* Role colors match the original dashboard; show every email in a vertical stack. */
.pf-zone.pf-collaborators { position: relative; width: 280px; height: 86px; min-height: 0; padding: 7px 16px; flex-direction: column; align-items: stretch; gap: 5px; }
.pf-email-stack { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; min-height: 0; overflow-y: auto; overscroll-behavior: auto; scrollbar-width: thin; padding-right: 5px; }
.pf-email-stack > * { flex-shrink: 0; }
.pf-email-stack:focus-visible { outline: 2px solid #47606f; outline-offset: -2px; }
.pf-row-subdued { background: #f4f4f3; }
.pf-row-subdued { --pf-muted-opacity: .62; }
.pf-row-subdued:hover, .pf-row-subdued:focus-within { --pf-muted-opacity: .85; }
/* Apply muting below the tile wrapper so only earned turnaround bands escape it. */
/* The Due cell and its button are excluded here: a filter on an ancestor would grey the green band too. */
.pf-row-subdued .pf-body > :not(.pf-photostrip, .pf-due-cell),
.pf-row-subdued .pf-due-cell > :not(.pf-due),
.pf-row-subdued .pf-photo,
.pf-row-subdued .pf-due .pf-date-inner > :not(.pf-turnaround-under-1, .pf-turnaround-under-2, .pf-turnaround-under-3, .pf-turnaround-under-5) {
    filter: grayscale(.85);
    opacity: var(--pf-muted-opacity);
}
.pf-email-chip { display: block; max-width: 100%; padding: 3px 7px; border: 1px solid #2196f3; border-radius: 4px; background: #e3f2fd; color: #26231f; font-size: 11px; line-height: 1.25; overflow-wrap: anywhere; }
.pf-email-chip--inspector { background: #ffe0b2; border-color: #ff9800; }
.pf-email-chip--author { background: #8b8b8b; border-color: #8b8b8b; color: #fff; }
.pf-email-chip--support { background: #f3e5f5; border-color: #ba68c8; }
.pf-email-chip--support::before { content: 'Support · '; font-weight: 600; color: #6a1b9a; }
.pf-no-people { font-size: 12px; color: #857e73; }
.pf-collaborators .pf-email-stack { align-items: stretch; }
.pf-collaborators .pf-email-chip { width: 100%; }
.pf-people-dialog { width: 480px; max-height: calc(100vh - 32px); overflow-y: auto; }
.pf-people-address { margin: 5px 0 0; font-size: 12px; color: #857e73; }
.pf-people-fields { border: 0; padding: 0 20px; margin: 0; min-width: 0; }
.pf-person-section { padding: 15px 0; border-top: 1px solid #f1ede2; }
.pf-person-heading { display: flex; align-items: center; justify-content: space-between; font-size: 12px; font-weight: 700; margin-bottom: 9px; }
.pf-person-heading > span { color: #948a77; font-size: 10px; font-weight: 400; }
.pf-person-current { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 7px; }
.pf-person-list { display: flex; flex-direction: column; }
.pf-person-empty { font-size: 12px; color: #948a77; }
.pf-person-remove { border: 0; background: transparent; color: #ad4a2e; padding: 4px; font-size: 11px; cursor: pointer; }
.pf-email-form { display: flex; gap: 8px; margin-top: 10px; }
.pf-email-form input { min-width: 0; flex: 1; width: 0; border: 1px solid #e7e2d8; border-radius: 8px; padding: 9px 11px; font-size: 13px; background: #fbfaf7; }
.pf-email-form button { white-space: nowrap; font-size: 12px; padding: 9px 12px; }
.pf-people-dialog .pf-person-section > .pf-email-chip { display: inline-block; }

/* Reuse the legacy conversation and its cache; reverse its chronological bubbles
   only in the compact B cell. The full notes modal retains its existing layout. */
.pf-body .pf-notes { height: 72px; /* 86px row minus the 14px progress strip above it */ flex-direction: column; align-items: stretch; gap: 4px; padding: 7px 12px; }
.pf-notes .dashboard-note-thread { flex: 1; min-height: 0; margin: 0; padding: 0; border: 0; background: transparent; overflow: hidden; }
.pf-notes .dashboard-note-thread__messages { display: flex; flex-direction: column; gap: 5px; height: 100%; min-height: 0; max-height: none; overflow-y: auto; overscroll-behavior: auto; scrollbar-width: thin; padding: 0 5px 0 0; }
.pf-notes .dashboard-note-thread__messages > * { flex-shrink: 0; }
.pf-notes .dashboard-note-message { width: 100%; }
/* The cell is ~58px tall: the note text leads (two lines max) and the author/time
   byline sits underneath on one line, so the newest note is readable without
   scrolling. The full text stays in the notes modal. */
.pf-notes .dashboard-note-message__bubble { position: relative; display: flex; flex-direction: column; max-width: 100%; padding: 2px 8px; border-radius: 9px 9px 9px 2px; font-size: 13px; }
.pf-notes .dashboard-note-message__body { order: 1; font-size: 14px; line-height: 18px; white-space: pre-wrap; overflow-wrap: anywhere; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; }
.pf-notes .dashboard-note-message__meta { order: 2; margin: 0; font-size: 10px; font-weight: 600; line-height: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; opacity: 0.8; }
.pf-notes .dashboard-note-message__edited { display: none; }
.pf-notes .dashboard-note-thread__composer, .pf-notes .dashboard-note-message__controls { display: none; }
.pf-notes .dashboard-note-thread__status:empty { display: none; }
.pf-notes-fallback { overflow-y: auto; min-height: 0; font-size: 15px; }

.pf-notes { cursor: pointer; }
.pf-notes-highlight { background: #fffbed; }
.pf-notes-highlight .dashboard-note-message__bubble { background: #fff6cf; border-color: #eee3b7; color: #383329; }
.pf-notes-fallback .pf-notetxt { font-size: 15px; white-space: normal; }

/* Readable conversation modal for dashboard B, including compose/edit states. */
#dashboardNotesModal .dashboard-note-message__body { font-size: 18px; line-height: 1.5; }
#dashboardNotesModal .dashboard-note-message__meta { font-size: 14px; line-height: 1.4; margin-bottom: 6px; }
#dashboardNotesModal .dashboard-note-message__bubble { padding: 12px 14px; max-width: 95%; }
#dashboardNotesModal .dashboard-note-message__controls { position: static; justify-content: flex-end; gap: 6px; margin-bottom: 4px; }
#dashboardNotesModal .dashboard-note-message__control { width: 36px; height: 36px; font-size: 20px; line-height: 36px; }
#dashboardNotesModal .dashboard-note-message__edited,
#dashboardNotesModal .dashboard-note-thread__status,
#dashboardNotesModal .dashboard-note-thread__empty { font-size: 14px; line-height: 1.4; }
#dashboardNotesModal .dashboard-note-thread__input,
#dashboardNotesModal .dashboard-note-message__edit-input { font-size: 18px; line-height: 1.5; min-height: 52px; padding: 10px 12px; }
#dashboardNotesModal .dashboard-note-thread__send,
#dashboardNotesModal .dashboard-note-message__edit-actions button { min-height: 48px; padding: 10px 16px; font-size: 16px; }

.pf-calendar-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 20px; border-top: 1px solid #f1ede2; font-size: 13px; }
.pf-calendar-actions small { flex-basis: 100%; color: #746c60; font-size: 12px; }
.pf-calendar-actions .inspection-calendar-handoff-btn { min-width: 36px; min-height: 36px; }

.pf-notes:focus-visible { outline: 2px solid #47606f; outline-offset: -2px; }

/* Larger type and controls in the people editor. */
.pf-people-dialog { width: 560px; }
.pf-people-dialog .pf-modal-title { font-size: 22px; }
.pf-people-dialog .pf-people-address { font-size: 16px; line-height: 1.5; }
.pf-people-dialog .pf-person-heading { font-size: 18px; }
.pf-people-dialog .pf-person-heading > span { font-size: 14px; }
.pf-people-dialog .pf-email-chip { font-size: 16px; line-height: 1.5; padding: 5px 9px; }
.pf-people-dialog .pf-person-empty,
.pf-people-dialog .pf-save-status { font-size: 16px; line-height: 1.5; }
.pf-people-dialog .pf-email-form input { font-size: 18px; line-height: 1.5; min-height: 48px; }
.pf-people-dialog .pf-email-form button,
.pf-people-dialog .pf-person-remove,
.pf-people-dialog .pf-done { font-size: 16px; min-height: 44px; }
.pf-people-dialog .pf-modal-x { width: 40px; height: 40px; }
.pf-people-dialog .pf-modal-x svg { width: 20px; height: 20px; }
@media (max-width: 480px) {
    .pf-people-dialog .pf-email-form { flex-wrap: wrap; }
    .pf-people-dialog .pf-email-form input { flex-basis: 100%; width: 100%; }
}

.pf-collaborators { cursor: pointer; }
.pf-collaborators:focus-visible { outline: 2px solid #47606f; outline-offset: -2px; }

.pf-sketch-tile-cell { display: flex; align-items: center; flex-shrink: 0; padding: 9px 16px; border-left: 1px solid #f1ede2; }
.pf-sketch-tile { display: flex; align-items: center; justify-content: center; width: 68px; height: 68px; border-radius: 8px; background: #f7f9fa; }
.pf-sketch-tile img { display: block; width: 68px; height: 68px; filter: grayscale(.85); opacity: .46; mix-blend-mode: multiply; }
.pf-sketch-tile:hover { background: #edf1f3; }
.pf-sketch-tile:focus-visible { outline: 2px solid #47606f; outline-offset: 2px; }
.pf-sketch-tile-unavailable { opacity: .35; }

.pf-property .pf-address-line { margin: 12px 16px 0; }

/* Green palette: 80% of the way from the Sep 11 soft set toward the legacy ppCompX neons; thresholds unchanged. */
.pf-date-band.pf-turnaround-under-1 { background: #56f71f; color: #173b0c; }
.pf-date-band.pf-turnaround-under-2 { background: #97f977; color: #173b0c; }
.pf-date-band.pf-turnaround-under-3 { background: #cafbba; color: #173b0c; }
.pf-date-band.pf-turnaround-under-5 { background: #ecfde7; color: #173b0c; }
/* Rush order (newfile Options chip, option_RUSH): the due tile's top band reads RUSH in crimson. */
.pf-due.pf-due-rush .pf-date-inner { box-shadow: 0 0 0 1px #e8b9b4, 0 1px 2px rgba(38,35,31,.10); }
.pf-due.pf-due-rush .pf-date-band:first-child { background: #b3261e; color: #fff; letter-spacing: .1em; }
.pf-due.pf-due-rush .pf-date-day { color: #a12a2a; }

.pf-sketch-link-dialog { width: 480px; }
.pf-sketch-link-dialog .pf-modal-field { font-size: 14px; }
.pf-sketch-link-dialog input { font-size: 18px; }
.pf-sketch-link-dialog .dashboard-sketch-url-row { display: flex; justify-content: flex-end; }
.pf-sketch-link-dialog .dashboard-sketch-add-to-report-btn { font-size: 16px; min-height: 44px; }

.pf-property > .pf-badges { margin: 8px 16px 0; }
.pf-property .pf-address { width: 100%; min-width: 0; }


.pf-column-headings { display: grid; grid-template-columns: 86px 86px 414px 101px minmax(0, 1fr) 101px 280px 101px; width: 1649px; box-sizing: border-box; padding: 0 1px; color: #766d60; font-size: 12px; font-weight: 600; }
.pf-column-headings > span { padding: 8px 16px 2px; }
.pf-column-headings > .pf-heading-pictures { padding-left: 9px; }

.pf-row-actions { width: 101px; height: 86px; flex-shrink: 0; border-left: 1px solid #f1ede2; display: flex; flex-wrap: wrap; align-content: space-evenly; align-items: center; justify-content: space-around; gap: 2px; padding: 3px; }
.pf-body .pf-row-actions button { display: flex !important; align-items: center; justify-content: center; width: 28px; min-width: 0; height: 34px; padding: 2px; margin: 0; border: 0; border-radius: 4px; font-size: 14px; filter: grayscale(.9); opacity: .72; }
.pf-row-actions button img { width: 24px !important; height: 24px !important; object-fit: contain; }
.pf-row-actions button:hover, .pf-row-actions button:focus-visible { background-color: #f0ede6; opacity: 1; }
/* Drive-by reports add a seventh desktop icon; tighten to three rows instead of clipping it.
   Scoped to the desktop layout: mobile cards hide that icon and keep their text button. */
@media screen and (min-width: 901px), screen and (orientation: landscape) {
    .pf-body .pf-row-actions:has(> button:nth-of-type(7)) button { height: 25px; padding: 0 2px; }
    .pf-row-actions:has(> button:nth-of-type(7)) button img { width: 22px !important; height: 22px !important; }
}

/* A shared grid keeps headings and rows aligned as B columns are hidden. */
#tableContent .pf-custom-columns .pf-table,
#tableContent .pf-custom-columns .pf-table > tbody,
#tableContent .pf-custom-columns .pf-table > tbody > tr > .pf-cell,
.pf-custom-columns .pf-row,
.pf-custom-columns .pf-column-headings { width: 100% !important; min-width: var(--pf-columns-width) !important; }
.pf-custom-columns .pf-body,
.pf-custom-columns .pf-column-headings { display: grid; grid-template-columns: var(--pf-columns-grid); }
/* Row height = tile (68px) + 9px padding top and bottom, so the row matches the Pictures and Due tiles. */
.pf-custom-columns .pf-body { min-height: 86px; }
.pf-custom-columns .pf-column-hidden { display: none !important; }
.pf-custom-columns .pf-column-headings > .pf-column-heading { display: flex; align-items: center; justify-content: space-between; padding: 5px 7px 2px 9px; min-width: 0; }
.pf-column-hide, .pf-columns-button { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; width: 24px; height: 26px; padding: 0; border: 0; border-radius: 5px; background: transparent; color: #8a8174; cursor: pointer; }
.pf-column-hide { opacity: .35; font-size: 17px; width: 20px; }
.pf-column-heading:hover .pf-column-hide, .pf-column-hide:focus-visible { opacity: 1; }
.pf-column-hide:hover, .pf-columns-button:hover { background: #eae5db; color: #383329; }
.pf-columns-button { align-self: center; justify-self: center; position: sticky; right: 0; background: #f8f6f1; }
.pf-columns-customized { color: #315c72; background: #e5eef2; }
.pf-columns-menu { position: fixed; inset: auto; margin: 0; box-sizing: border-box; width: 210px; max-height: calc(100vh - 16px); overflow-y: auto; padding: 12px; border: 1px solid #e7e2d8; border-radius: 10px; background: #fff; color: #514a40; box-shadow: 0 10px 35px #26231f26; font: 13px -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; }
.pf-columns-menu strong { display: block; margin: 2px 6px 8px; font-size: 12px; }
.pf-columns-menu label { display: flex; align-items: center; gap: 10px; padding: 7px 6px; border-radius: 5px; cursor: pointer; }
.pf-columns-menu label:hover { background: #f5f2ed; }
.pf-columns-menu input { width: 15px; height: 15px; margin: 0; accent-color: #47606f; }
.pf-columns-menu > button { width: 100%; margin-top: 8px; padding: 8px; border: 1px solid #e7e2d8; border-radius: 5px; background: #f8f6f1; color: #47606f; cursor: pointer; }
.pf-columns-menu > button:disabled { opacity: .45; cursor: default; }
.pf-column-hide:focus-visible, .pf-columns-button:focus-visible, .pf-columns-menu :focus-visible { outline: 2px solid #47606f; outline-offset: 2px; }
@media print { .pf-column-hide, .pf-columns-button, .pf-columns-menu { display: none !important; } }

/* Pictures and Due are independent cells; retain only the outer row outline. */
.pf-due-cell { display: flex; align-items: center; padding: 9px; }
.pf-dashboard .pf-body > * { border-left: 0; border-right: 0; }

/* Let address chips wrap without clipping a loan number or existing actions. */
.pf-body .pf-property { height: auto; min-height: 86px; align-self: stretch; padding-bottom: 8px; }
.pf-property > .pf-badges { flex-wrap: wrap; align-items: center; row-gap: 4px; }
.pf-property .pf-loan-number { max-width: 100%; overflow-wrap: anywhere; }

.pf-body .pf-due:hover .pf-date-inner { box-shadow: 0 3px 10px rgba(38,35,31,.18); }

/* Keep progress aligned above Notes as visible columns change. */
.pf-body > .pf-timeline { grid-column: var(--pf-progress-column, 5); grid-row: 1; align-self: start; }
.pf-body > [data-pf-column] { grid-column: var(--pf-cell-column); grid-row: 1 / span 2; }
.pf-body > [data-pf-column="notes"] { grid-row: 2; }
.pf-progress-unavailable .pf-body > .pf-timeline { display: none; }
.pf-body > .pf-property .pf-address-line { margin-top: 8px; }

/* Flexible text cells absorb spare width while icon tiles retain their size. */
.pf-custom-columns .pf-body > [data-pf-column] { width: 100%; min-width: 0; }

/* Clickable row surfaces include their nested text and artwork. */
.pf-row :is(button, a[href], [role="button"], [onclick], [data-pf-notes-cell], [data-pf-edit-people]),
.pf-row :is(button, a[href], [role="button"], [onclick], [data-pf-notes-cell], [data-pf-edit-people]) :not(input, textarea, select) { cursor: pointer; }
.pf-row :is(button:disabled, [aria-disabled="true"]),
.pf-row :is(button:disabled, [aria-disabled="true"]) * { cursor: default; }

.pf-dashboard .pf-drive-by { color: #47606f; text-decoration: underline; font-size: 12px; line-height: 1.4; }
.pf-dashboard .pf-sketch-tile-cell { flex-direction: column; justify-content: center; gap: 6px; }
/* This popup must work before the metadata editor has ever been opened. */
#driveByModal { display: none; position: fixed; inset: 0; z-index: 10000; background: #0008; padding: 16px; box-sizing: border-box; }
#driveByModal.show { display: flex; align-items: center; justify-content: center; }
#driveByModal .meta-edit-content { background: white; border-radius: 8px; width: 100%; max-height: calc(100dvh - 32px); display: flex; flex-direction: column; }
#driveByModal .meta-edit-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid #ddd; }
#driveByModal h2 { margin: 0; }
#driveByModal .meta-edit-close { border: 0; background: transparent; font-size: 28px; cursor: pointer; }
#driveByModal .meta-edit-body { overflow-y: auto; min-height: 0; }
#driveByModal .meta-edit-footer { border-top: 1px solid #ddd; }
#driveByModal input, #driveByModal select { box-sizing: border-box; }

/* Density is a presentation preference; the same row controls and data remain mounted. */
.pf-view-controls { display: flex; align-items: center; justify-content: center; gap: 4px; position: sticky; right: 0; background: #f8f6f1; }
.pf-density-button[aria-pressed="true"] { background: #e5eef2; }
.pf-density-button img { object-fit: contain; }
@media screen and (min-width: 901px), screen and (orientation: landscape) {
    .pf-compact.pf-custom-columns .pf-body { height: 48px; min-height: 48px; grid-template-rows: 14px 34px; }
    #tableContent .pf-compact .pf-table { border-spacing: 0 3px; }
    .pf-compact .pf-row { border-radius: 5px; }
    .pf-compact .pf-column-headings { font-size: 10px; }
    .pf-compact .pf-column-hide { width: 12px; font-size: 13px; }
    .pf-compact .pf-body > :is(.pf-photostrip, .pf-due-cell, .pf-zone-tile, .pf-sketch-tile-cell) { padding: 3px 5px; }
    .pf-compact .pf-photo, .pf-compact .pf-sketch-tile, .pf-compact .pf-sketch-tile img { width: 30px; height: 30px; border-radius: 4px; }
    .pf-compact .pf-photo .pf-badge { width: 14px; height: 14px; right: 1px; bottom: 1px; }
    .pf-compact .pf-photo .pf-badge svg { width: 10px; height: 10px; }
    .pf-compact .pf-date { width: 30px; height: 30px; }
    .pf-compact .pf-date-inner { border-radius: 4px; }
    .pf-compact .pf-date-band { font-size: 7px; line-height: 8px; padding: 0; }
    .pf-compact .pf-date-day { font-size: 14px; }
    .pf-compact .pf-body > .pf-property { height: 48px; min-height: 0; padding: 3px 0; overflow: hidden; }
    .pf-compact .pf-body > .pf-property .pf-address-line { margin: 0 8px; align-items: center; gap: 4px; }
    .pf-compact .pf-address { font-size: 14px; overflow: hidden; text-overflow: ellipsis; }
    .pf-compact .pf-property > .pf-badges { margin: 3px 8px 0; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
    .pf-compact .pf-property .pf-badge { flex-shrink: 0; font-size: 9px; padding: 2px 4px; white-space: nowrap; }
    .pf-compact .pf-property .pf-loan-number { max-width: none; }
    .pf-compact .pf-body .pf-notes { height: 34px; padding: 1px 8px; gap: 0; overflow: hidden; }
    .pf-compact .pf-notes .dashboard-note-thread__messages { overflow: hidden; }
    .pf-compact .pf-notes .dashboard-note-message__bubble { padding: 0 4px; }
    .pf-compact .pf-notes .dashboard-note-message__meta { font-size: 9px; line-height: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .pf-compact .pf-notes .dashboard-note-message__body,
    .pf-compact .pf-notes .pf-notetxt { display: block; font-size: 12px; line-height: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .pf-compact .pf-notes-fallback { overflow: hidden; }
    .pf-compact .pf-collaborators { height: 48px; padding: 3px 8px; overflow: hidden; }
    .pf-compact .pf-email-stack { max-height: 42px; gap: 2px; }
    .pf-compact .pf-email-chip { padding: 1px 4px; font-size: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .pf-compact .pf-sketch-tile-cell { gap: 0; }
    .pf-compact .pf-row-actions { height: 48px; padding: 1px; gap: 0; }
    .pf-compact .pf-body .pf-row-actions button { height: 22px; width: 28px; }
    .pf-compact .pf-row-actions button img { width: 18px !important; height: 18px !important; }
    /* Compact rows have room for two rows only: fit seven icons four across. */
    .pf-compact .pf-body .pf-row-actions:has(> button:nth-of-type(7)) button { width: 22px; height: 22px; padding: 0; }
    .pf-compact .pf-row-actions:has(> button:nth-of-type(7)) button img { width: 18px !important; height: 18px !important; }
}
@media print { .pf-view-controls { display: none !important; } }

/* Revisions reuses the Cancel slot; inactive styling stays identical. */
.pf-body .pf-node[data-pf-step="REV"].pf-node-on,
.pf-row-subdued .pf-body .pf-node[data-pf-step="REV"].pf-node-on {
    background: #ffe4e6; border-color: #fb7185; color: #be123c;
}

/* Scheduling contact stays read-only and uses the report already in memory. */
.pf-inspection-contact { margin: 0 20px 16px; padding: 14px 16px; background: #f6f8f7; border: 1px solid #e2e8e5; border-radius: 10px; display: flex; flex-direction: column; gap: 5px; }
.pf-contact-label { color: #78847e; text-transform: uppercase; font-size: 10px; letter-spacing: .08em; }
.pf-contact-details { display: flex; flex-direction: column; gap: 3px; color: #59645f; font-size: 13px; overflow-wrap: anywhere; }
.pf-contact-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 7px; }
.pf-contact-actions a { padding: 6px 12px; border: 1px solid #ccd8d2; border-radius: 6px; color: #3e5b50; background: white; text-decoration: none; font-size: 13px; }
.pf-contact-actions a:hover { background: #eaf0ed; }

/* Saved templates belong to a library, not the appraisal pipeline. */
.pf-toolbar .pf-templates-link { border: 0; background: transparent; color: #47606f; padding: 8px 4px; white-space: nowrap; font-size: 13px; }
.pf-toolbar .pf-templates-link:hover { text-decoration: underline; }
.pf-template-back { border: 0; background: transparent; color: #47606f; cursor: pointer; padding: 0 4px 14px; }
.pf-results-heading { margin: 0; padding: 7px 8px 12px; font-size: 14px; font-weight: 600; color: #536674; }
.pf-results-heading span { margin-left: 6px; color: #8a857c; font-size: 12px; font-weight: 400; }
.pf-templates-section { margin-top: 22px; padding-top: 18px; border-top: 1px solid #ece8e0; }
.pf-templates-browse { margin-top: 0; padding-top: 0; border-top: 0; }
.pf-template-row { display: flex; align-items: center; gap: 12px; margin: 0 4px 7px; padding: 13px 14px; border: 1px solid #e4e8eb; border-radius: 8px; background: #fafcfd; }
.pf-template-icon { display: grid; place-items: center; width: 35px; height: 39px; flex-shrink: 0; border: 1px solid #d9e1e6; border-radius: 4px; background: #fff; color: #6c8390; font-size: 20px; }
.pf-template-description { min-width: 0; }
.pf-template-name { color: #435c6b; font-size: 14px; font-weight: 600; overflow-wrap: anywhere; }
.pf-template-badge { display: inline-block; margin-left: 8px; padding: 4px 7px; border-radius: 4px; background: #eaf0f4; color: #617e8e; font-size: 10px; font-weight: 600; letter-spacing: .5px; }
.pf-template-meta { margin-top: 4px; color: #918b81; font-size: 11px; }
.pf-template-row button { flex-shrink: 0; margin-left: auto; padding: 7px 12px; border: 1px solid #d6dee3; border-radius: 6px; background: #fff; color: #47606f; cursor: pointer; font-size: 12px; }
.pf-template-empty { padding: 20px 8px; color: #80786b; font-size: 13px; }
@media (max-width: 768px) {
    .pf-toolbar { flex-wrap: wrap; }
    .pf-toolbar input { flex-basis: calc(100% - 100px); }
    .pf-toolbar .pf-templates-link { margin-left: auto; }
    .pf-template-row { gap: 8px; padding: 10px; }
    .pf-template-name { font-size: 12px; }
    .pf-template-icon { width: 26px; }
    .pf-template-badge { margin: 4px 0 0; }
    .pf-template-row button { padding: 7px; font-size: 11px; }
}
@media print {
    .pf-toolbar, .pf-template-back, .pf-templates-section { display: none !important; }
}
