/* Audit refinements: scoped presentation only; business states retain their colors. */
#parts-data-review:empty { display: none; }
#parts-data-review { margin: 6px 0; padding: 8px 10px; color: #754315; background: #fff7e5; border-left: 3px solid #a66612; font-size: 12px; }
.sample-review-label { color: #754315; font-size: 11px; }
.app-shell { background: #f3f5f7; }
.app-shell .sidebar { background: #243240; }
.app-shell .nav-item.active { background: #405165; }
.app-shell .view .soft-button { background: #f1f4f7; color: #263748; border-color: #bac6d1; }
#workspace-save-feedback { margin-top: 4px; font-size: 12px; font-weight: 600; color: #334155; }
#visit-payment-reminder { display: block; margin-top: 5px; min-height: 36px; padding: 5px 8px; background: #fff3cb; color: #713f12; border: 1px solid #b88732; border-radius: 4px; font-size: 12px; text-align: left; }
#visit-payment-reminder[hidden] { display: none; }
.planner-status-legend label { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: #334155; }
.planner-status-legend input { width: 16px; height: 16px; margin: 0; }
#view-dispatch #dispatch-board.planner-fit .planner-matrix { min-width: calc(88px + var(--planner-columns, 4) * 180px); }
#view-dispatch .planner-matrix thead th { position: sticky; top: 0; z-index: 2; }
#view-dispatch .planner-matrix thead .planner-time-heading { z-index: 3; }
#view-dispatch .planner-tech-title strong { white-space: normal; overflow-wrap: anywhere; }
#service-photo-section.photo-overview #attachment-grid { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
#service-photo-section.photo-overview .attachment-card { flex: 0 0 110px; min-width: 0; padding: 0; overflow: hidden; border: 1px solid #cbd5e1; border-radius: 4px; }
#service-photo-section.photo-overview .attachment-preview { display: block; height: 100px; min-height: 0; position: relative; }
#service-photo-section.photo-overview .attachment-preview img { width: 100%; height: 100%; object-fit: cover; }
#service-photo-section.photo-overview .attachment-preview span { position: absolute; right: 2px; bottom: 2px; padding: 2px 4px; background: #fff; color: #1e293b; font-size: 11px; }
#ticket-detail-modal #detail-visits-panel #service-photo-section.photo-overview :is(.attachment-type-field, .attachment-card-actions) { display: none !important; }
#photo-manage-toggle { min-height: 36px; padding: 5px 9px; font-size: 12px; }
#view-intake .intake-admin-controls { display: block; }
#view-intake .intake-admin-controls.hidden { display: none; }
.intake-admin-controls > summary, .user-access-more > summary { cursor: pointer; min-height: 36px; padding: 8px 0; color: #334155; font-size: 13px; font-weight: 600; }
.user-access-more { grid-column: 1 / -1; border-top: 1px solid #e2e8f0; }
.user-access-more .portal-id-fields { margin: 6px 0; }
#claim-amount-detail-toggle { min-height: 32px; font-size: 12px; }
@media screen {
  #claim-settlement-print-area:not(.show-amount-detail) .claim-settlement-table :is(th, td):is(:nth-child(6), :nth-child(7), :nth-child(9), :nth-child(10)) { display: none; }
  #claim-settlement-print-area:not(.show-amount-detail) .claim-settlement-table { min-width: 860px; width: 100%; table-layout: auto; }
  #claim-settlement-print-area:not(.show-amount-detail) .claim-settlement-table th { width: auto; min-width: 90px; padding: 8px; }
  .claim-settlement-table :is(th, td) { overflow-wrap: normal; word-break: normal; }
  .claim-settlement-table :is(th, td):is(:nth-child(2), :nth-child(8), :nth-child(11), :nth-child(12)) { white-space: nowrap; }
  .invoice-list-table :is(th, td):last-child { position: sticky; right: 0; background: #fff; box-shadow: -1px 0 #e2e8f0; }
}
#ticket-list-panel td:nth-child(7) { overflow: visible; white-space: normal; text-overflow: clip; min-width: 70px; }
#ticket-form > label { align-self: start; }
#ticket-form > label > :is(input, select) { margin-top: 0; }
#view-overview .hero-card { box-shadow: none; background: #fff; border-color: #d8e0e8; color: #1e293b; }
#view-overview .hero-card :is(h2, p, .section-kicker, strong) { color: #1e293b; }
#view-overview .hero-stat :is(span, small) { color: #475569; }
#view-overview .load-meta { font-size: 12px; }
@media (min-width: 1100px) {
  .app-shell #view-parts .parts-summary { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
.report-scope-definition { margin: 6px 0; color: #475569; font-size: 12px; }
.audit-help { border-bottom: 1px solid #d8e0e8; margin: 6px 0; background: transparent; }
.audit-help > summary { cursor: pointer; min-height: 36px; padding: 8px 0; font-size: 13px; font-weight: 600; color: #334155; }
#view-intake .intake-rules { background: #f1f4f7; color: #334155; border: 1px solid #d8e0e8; box-shadow: none; }
#view-intake .intake-rules :is(h3, li, span) { color: #334155; }
#view-advisor :is(.advisor-scope-note, .advisor-method-note), #view-ai .report-note { background: #f8fafc; box-shadow: none; }
@media (max-width: 820px) {
  #ticket-detail-modal #service-photo-section .service-photo-heading { display: flex; flex-direction: row; align-items: center; justify-content: space-between; gap: 6px; padding: 4px 0; margin-bottom: 6px; }
  #ticket-detail-modal #service-photo-section #attachment-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; padding: 0; border: 0; border-radius: 0; box-shadow: none; }
  #ticket-detail-modal #service-photo-section #attachment-form > label { grid-column: auto; margin: 0; padding: 0; min-width: 0; gap: 3px; font-size: 12px; }
  #ticket-detail-modal #service-photo-section #attachment-form :is(select, input[type=file]) { width: 100%; min-width: 0; min-height: 44px; padding: 4px; }
  #ticket-detail-modal #service-photo-section #attachment-files { font-size: 12px; }
  #ticket-detail-modal #service-photo-section #attachment-file-summary { grid-column: 1; padding: 3px; min-height: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; font-size: 12px; }
  #ticket-detail-modal #service-photo-section #attachment-upload-button { grid-column: 2; min-height: 44px; padding: 6px; font-size: 13px; }
  #service-photo-section.photo-overview #attachment-grid { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 6px; }
  #service-photo-section.photo-overview .attachment-card { flex-basis: 96px; }
  #service-photo-section.photo-overview .attachment-preview { height: 88px; }
  #visit-payment-reminder, #photo-manage-toggle { min-height: 44px; }
  .planner-status-legend label { min-height: 44px; }
  #view-dispatch #dispatch-board.planner-fit .planner-matrix { min-width: calc(88px + var(--planner-columns, 4) * 210px); }
  #ticket-detail-modal #detail-visits-panel .service-diagnosis-field textarea { min-height: 144px; font-size: 16px; line-height: 1.5; }
}
