/**
 * Reports visual language, matched to Home / Jobs / Insights / Inventory.
 * Scoped to #tab-reports.reports-2026. Formulas, CSV, and overlay opens stay in reports.js.
 */

#app-shell .app-main:has(#tab-reports.reports-2026:not(.is-hidden)) {
  padding-left: 0;
  padding-right: 0;
  padding-bottom: 0;
  background: #eceef1;
  min-width: 0;
  overflow-x: hidden;
}

#app-shell #tab-reports.reports-2026 {
  --rpt-ink: #1c1f26;
  --rpt-panel: #ffffff;
  --rpt-mist: #eceef1;
  --rpt-paper: #f4f5f7;
  --rpt-accent: #0369a1;
  --rpt-accent-hover: #025887;
  --rpt-line: color-mix(in srgb, var(--rpt-ink) 10%, transparent);
  --rpt-ok: #166534;
  --rpt-warn: #b45309;
  --rpt-money: #0369a1;
  --rpt-pipeline: #0f766e;
  --rpt-clients: #6d28d9;
  --font-rpt-display: "Space Grotesk", ui-sans-serif, system-ui, sans-serif;
  --font-rpt-body: "Source Sans 3", ui-sans-serif, system-ui, sans-serif;
  font-family: var(--font-rpt-body);
  color: var(--rpt-ink);
  background: var(--rpt-mist);
  display: flex;
  flex-direction: column;
  min-height: 100%;
  min-width: 0;
  max-width: 100%;
  overflow-x: clip;
}

#app-shell #tab-reports.reports-2026 .reports-2026-page {
  display: flex;
  flex-direction: column;
  flex: 1 1 0;
  min-height: 0;
  min-width: 0;
  background: var(--rpt-mist);
}

#app-shell #tab-reports.reports-2026 .reports-hero {
  background: var(--rpt-paper);
  color: var(--rpt-ink);
  margin: 0;
  padding: 1.5rem 1.5rem 1.35rem;
  border-bottom: 1px solid var(--rpt-line);
  flex-shrink: 0;
  min-width: 0;
}

@media (min-width: 900px) {
  #app-shell #tab-reports.reports-2026 .reports-hero {
    padding: 1.85rem 2.25rem 1.5rem;
  }
}

@media (max-width: 767px) {
  #app-shell #tab-reports.reports-2026 .reports-hero {
    padding-left: 1.15rem;
    padding-right: 1.15rem;
  }
}

#app-shell #tab-reports.reports-2026 .reports-kicker {
  margin: 0 0 0.65rem;
  font-family: var(--font-rpt-display);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--rpt-ink) 45%, transparent);
}

#app-shell #tab-reports.reports-2026 .reports-hero-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.85rem 1.25rem;
}

#app-shell #tab-reports.reports-2026 .reports-display {
  margin: 0;
  font-family: var(--font-rpt-display);
  font-size: clamp(2rem, 4.2vw, 3.35rem);
  font-weight: 600;
  letter-spacing: -0.045em;
  line-height: 0.95;
  color: var(--rpt-ink);
}

#app-shell #tab-reports.reports-2026 .reports-hero-lead {
  margin: 0.75rem 0 0;
  max-width: 38rem;
  font-size: 1.05rem;
  line-height: 1.5;
  color: color-mix(in srgb, var(--rpt-ink) 62%, transparent);
}

#app-shell #tab-reports.reports-2026 .reports-hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  margin-left: auto;
  flex-shrink: 0;
}

#app-shell #tab-reports.reports-2026 .reports-back {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border: 1px solid var(--rpt-line);
  border-radius: 999px;
  padding: 0.5rem 0.95rem 0.5rem 0.75rem;
  background: var(--rpt-panel);
  color: var(--rpt-ink);
  font-family: var(--font-rpt-display);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transform: none;
}

#app-shell #tab-reports.reports-2026 .reports-back:hover,
#app-shell #tab-reports.reports-2026 .reports-back:focus-visible {
  border-color: var(--rpt-accent);
  color: var(--rpt-accent);
  background: rgba(3, 105, 161, 0.06);
}

#app-shell #tab-reports.reports-2026 .reports-back-icon {
  display: inline-flex;
  width: 1rem;
  height: 1rem;
}

#app-shell #tab-reports.reports-2026 .reports-back-icon svg {
  width: 100%;
  height: 100%;
}

#app-shell #tab-reports.reports-2026 .reports-export-btn {
  border-radius: 999px;
  font-family: var(--font-rpt-display);
  font-weight: 700;
  background: var(--rpt-accent);
  border-color: var(--rpt-accent);
  transform: none;
}

#app-shell #tab-reports.reports-2026 .reports-export-btn:hover:not(:disabled) {
  background: var(--rpt-accent-hover);
  border-color: var(--rpt-accent-hover);
  transform: none;
}

#app-shell #tab-reports.reports-2026 .reports-export-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

#app-shell #tab-reports.reports-2026 .reports-hero-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 0.85rem;
  margin-top: 1.15rem;
}

#app-shell #tab-reports.reports-2026 .reports-search {
  position: relative;
  display: flex;
  align-items: center;
  flex: 1 1 18rem;
  min-width: 0;
  max-width: 32rem;
}

#app-shell #tab-reports.reports-2026 .reports-search--detail {
  max-width: 22rem;
  flex: 1 1 14rem;
}

#app-shell #tab-reports.reports-2026 .reports-search-icon {
  position: absolute;
  left: 0.9rem;
  display: inline-flex;
  width: 1.05rem;
  height: 1.05rem;
  color: color-mix(in srgb, var(--rpt-ink) 40%, transparent);
  pointer-events: none;
  z-index: 1;
}

#app-shell #tab-reports.reports-2026 .reports-search-icon svg {
  width: 100%;
  height: 100%;
}

#app-shell #tab-reports.reports-2026 .reports-search-input,
#app-shell #tab-reports.reports-2026 .reports-search-input.field {
  width: 100%;
  min-height: 2.5rem;
  padding-left: 2.45rem;
  border-radius: 999px !important;
  border: 1px solid var(--rpt-line);
  background: var(--rpt-panel);
  font-family: var(--font-rpt-body);
  color: var(--rpt-ink);
  box-shadow: none;
}

#app-shell #tab-reports.reports-2026 .reports-search-input:focus {
  border-color: var(--rpt-accent);
  box-shadow: 0 0 0 3px rgba(3, 105, 161, 0.14);
  outline: none;
}

#app-shell #tab-reports.reports-2026 .reports-hero-nav .btn-secondary,
#app-shell #tab-reports.reports-2026 .reports-filter-row .btn-secondary {
  border-radius: 999px;
  font-family: var(--font-rpt-display);
  font-weight: 600;
  transform: none;
}

#app-shell #tab-reports.reports-2026 .reports-2026-body {
  flex: 1 1 0;
  min-height: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: 1rem 1.5rem 1.5rem;
  container-type: inline-size;
  container-name: rpt-body;
}

@media (min-width: 900px) {
  #app-shell #tab-reports.reports-2026 .reports-2026-body {
    padding: 1.15rem 2.25rem 1.75rem;
  }
}

@media (max-width: 767px) {
  #app-shell #tab-reports.reports-2026 .reports-2026-body {
    padding-left: 1.15rem;
    padding-right: 1.15rem;
  }
}

#app-shell #tab-reports.reports-2026 .reports-hub {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  align-items: start;
}

@container rpt-body (min-width: 56rem) {
  #app-shell #tab-reports.reports-2026 .reports-hub {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

#app-shell #tab-reports.reports-2026 .reports-column,
#app-shell #tab-reports.reports-2026 .reports-filters {
  background: var(--rpt-panel) !important;
  border: 1px solid var(--rpt-line) !important;
  border-radius: 1.15rem !important;
  box-shadow: none !important;
  overflow: hidden;
}

#app-shell #tab-reports.reports-2026 .reports-column-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.95rem 1rem 0.85rem;
  background: var(--rpt-paper) !important;
  border-bottom: 1px solid var(--rpt-line);
}

#app-shell #tab-reports.reports-2026 .reports-column-head-copy {
  min-width: 0;
}

#app-shell #tab-reports.reports-2026 .reports-column-icon {
  width: 2.15rem;
  height: 2.15rem;
  border-radius: 0.7rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: rgba(3, 105, 161, 0.1) !important;
  color: var(--rpt-money) !important;
}

#app-shell #tab-reports.reports-2026 .reports-column-icon svg {
  width: 1.15rem;
  height: 1.15rem;
}

#app-shell #tab-reports.reports-2026 .reports-column--pipeline .reports-column-icon {
  background: rgba(15, 118, 110, 0.1) !important;
  color: var(--rpt-pipeline) !important;
}

#app-shell #tab-reports.reports-2026 .reports-column--clients .reports-column-icon {
  background: rgba(109, 40, 217, 0.1) !important;
  color: var(--rpt-clients) !important;
}

#app-shell #tab-reports.reports-2026 .reports-column-title {
  margin: 0;
  font-family: var(--font-rpt-display);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  text-transform: none;
  color: var(--rpt-ink);
}

#app-shell #tab-reports.reports-2026 .reports-column-count {
  margin: 0.15rem 0 0;
  font-size: 0.8125rem;
  color: color-mix(in srgb, var(--rpt-ink) 50%, transparent);
}

#app-shell #tab-reports.reports-2026 .reports-list {
  list-style: none;
  margin: 0;
  padding: 0.25rem 0;
}

#app-shell #tab-reports.reports-2026 .reports-item {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  width: 100%;
  text-align: left;
  border: none;
  background: transparent;
  padding: 0.85rem 1rem;
  cursor: pointer;
  color: inherit;
  font: inherit;
}

#app-shell #tab-reports.reports-2026 .reports-list li + li .reports-item {
  border-top: 1px solid var(--rpt-line);
}

#app-shell #tab-reports.reports-2026 .reports-item:hover,
#app-shell #tab-reports.reports-2026 .reports-item:focus-visible {
  background: rgba(3, 105, 161, 0.05);
  outline: none;
}

#app-shell #tab-reports.reports-2026 .reports-item-copy {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
  flex: 1 1 auto;
}

#app-shell #tab-reports.reports-2026 .reports-item-title {
  font-family: var(--font-rpt-display);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--rpt-ink);
}

#app-shell #tab-reports.reports-2026 .reports-item:hover .reports-item-title,
#app-shell #tab-reports.reports-2026 .reports-item:focus-visible .reports-item-title {
  color: var(--rpt-accent);
}

#app-shell #tab-reports.reports-2026 .reports-item-desc {
  font-size: 0.8125rem;
  line-height: 1.4;
  color: color-mix(in srgb, var(--rpt-ink) 55%, transparent);
}

#app-shell #tab-reports.reports-2026 .reports-item-chevron {
  display: inline-flex;
  width: 1rem;
  height: 1rem;
  margin-top: 0.2rem;
  color: color-mix(in srgb, var(--rpt-ink) 28%, transparent);
  flex-shrink: 0;
}

#app-shell #tab-reports.reports-2026 .reports-item-chevron svg {
  width: 100%;
  height: 100%;
}

#app-shell #tab-reports.reports-2026 .reports-item:hover .reports-item-chevron,
#app-shell #tab-reports.reports-2026 .reports-item:focus-visible .reports-item-chevron {
  color: var(--rpt-accent);
}

#app-shell #tab-reports.reports-2026 .reports-hub-empty {
  grid-column: 1 / -1;
  padding: 2.75rem 1.5rem;
  text-align: center;
  background: var(--rpt-panel);
  border: 1px solid var(--rpt-line);
  border-radius: 1.15rem;
}

#app-shell #tab-reports.reports-2026 .reports-hub-empty-title {
  margin: 0 0 0.35rem;
  font-family: var(--font-rpt-display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--rpt-ink);
}

#app-shell #tab-reports.reports-2026 .reports-hub-empty-body {
  margin: 0;
  font-size: 0.95rem;
  color: color-mix(in srgb, var(--rpt-ink) 55%, transparent);
}

#app-shell #tab-reports.reports-2026 .reports-detail {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-width: 0;
}

#app-shell #tab-reports.reports-2026 .reports-filters {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  padding: 0.95rem 1rem;
}

#app-shell #tab-reports.reports-2026 .reports-filter-block {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

#app-shell #tab-reports.reports-2026 .reports-filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 0.75rem;
}

#app-shell #tab-reports.reports-2026 .reports-filter-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 9rem;
}

#app-shell #tab-reports.reports-2026 .reports-filter-label {
  font-family: var(--font-rpt-display);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--rpt-ink) 45%, transparent);
}

#app-shell #tab-reports.reports-2026 .reports-range-chips,
#app-shell #tab-reports.reports-2026 .reports-status-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.2rem;
  padding: 0.2rem;
  background: var(--rpt-mist);
  border: 1px solid var(--rpt-line);
  border-radius: 1.15rem;
  width: fit-content;
  max-width: 100%;
}

#app-shell #tab-reports.reports-2026 .reports-range-chip {
  border: none !important;
  border-radius: 999px !important;
  padding: 0.45rem 0.85rem;
  font-family: var(--font-rpt-display);
  font-size: 0.8125rem;
  font-weight: 600;
  color: color-mix(in srgb, var(--rpt-ink) 50%, transparent);
  background: transparent !important;
  box-shadow: none !important;
  cursor: pointer;
}

#app-shell #tab-reports.reports-2026 .reports-range-chip:hover {
  color: var(--rpt-accent);
  background: rgba(3, 105, 161, 0.08) !important;
}

#app-shell #tab-reports.reports-2026 .reports-range-chip.is-active,
#app-shell #tab-reports.reports-2026 .reports-range-chip[aria-selected="true"] {
  background: rgba(3, 105, 161, 0.12) !important;
  border-color: transparent !important;
  color: var(--rpt-accent) !important;
}

#app-shell #tab-reports.reports-2026 .reports-range-chip:focus-visible {
  outline: 2px solid var(--rpt-accent);
  outline-offset: 1px;
}

#app-shell #tab-reports.reports-2026 .reports-custom-dates {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

#app-shell #tab-reports.reports-2026 .reports-custom-dates .field,
#app-shell #tab-reports.reports-2026 .reports-filter-field .field {
  border-radius: 0.7rem;
  border: 1px solid var(--rpt-line);
  min-height: 2.35rem;
}

#app-shell #tab-reports.reports-2026 .reports-range-note {
  margin: 0.15rem 0 0;
  font-size: 0.8125rem;
  color: color-mix(in srgb, var(--rpt-ink) 50%, transparent);
}

#app-shell #tab-reports.reports-2026 .reports-range-note--solo {
  margin: 0;
}

#app-shell #tab-reports.reports-2026 .reports-row-meta {
  margin: 0;
  font-size: 0.8125rem;
  color: color-mix(in srgb, var(--rpt-ink) 50%, transparent);
}

#app-shell #tab-reports.reports-2026 .reports-summary {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
}

@container rpt-body (min-width: 36rem) {
  #app-shell #tab-reports.reports-2026 .reports-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@container rpt-body (min-width: 56rem) {
  #app-shell #tab-reports.reports-2026 .reports-summary {
    grid-template-columns: repeat(var(--reports-summary-cols, 4), minmax(0, 1fr));
  }
}

#app-shell #tab-reports.reports-2026 .reports-summary-card {
  position: relative;
  background: var(--rpt-panel);
  border: 1px solid var(--rpt-line);
  border-radius: 1.05rem;
  padding: 1.05rem 1.1rem 1rem 1.2rem;
  overflow: hidden;
}

#app-shell #tab-reports.reports-2026 .reports-summary-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--rpt-accent);
}

#app-shell #tab-reports.reports-2026 .reports-summary-label {
  display: block;
  font-family: var(--font-rpt-display);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--rpt-ink) 45%, transparent);
}

#app-shell #tab-reports.reports-2026 .reports-summary-value {
  display: block;
  margin-top: 0.35rem;
  font-family: var(--font-rpt-display);
  font-size: clamp(1.35rem, 2.2vw, 1.85rem);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1.1;
  color: var(--rpt-ink);
}

#app-shell #tab-reports.reports-2026 .reports-table-wrap {
  background: var(--rpt-panel);
  border: 1px solid var(--rpt-line);
  border-radius: 1.15rem;
  overflow: auto;
  min-width: 0;
}

#app-shell #tab-reports.reports-2026 .reports-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

#app-shell #tab-reports.reports-2026 .reports-table th,
#app-shell #tab-reports.reports-2026 .reports-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--rpt-line);
  vertical-align: top;
}

#app-shell #tab-reports.reports-2026 .reports-table thead th {
  font-family: var(--font-rpt-display);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--rpt-ink) 45%, transparent);
  background: var(--rpt-paper);
  position: sticky;
  top: 0;
  z-index: 1;
}

#app-shell #tab-reports.reports-2026 .reports-table tbody tr:last-child td {
  border-bottom: none;
}

#app-shell #tab-reports.reports-2026 .reports-table tbody tr:hover td {
  background: rgba(3, 105, 161, 0.04);
}

#app-shell #tab-reports.reports-2026 .reports-table tbody tr[data-open-invoice],
#app-shell #tab-reports.reports-2026 .reports-table tbody tr[data-open-estimate],
#app-shell #tab-reports.reports-2026 .reports-table tbody tr[data-open-job],
#app-shell #tab-reports.reports-2026 .reports-table tbody tr[data-open-request],
#app-shell #tab-reports.reports-2026 .reports-table tbody tr[data-open-customer] {
  cursor: pointer;
}

#app-shell #tab-reports.reports-2026 .reports-cell--num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

#app-shell #tab-reports.reports-2026 .reports-table-empty,
#app-shell #tab-reports.reports-2026 .portal-table-empty {
  padding: 2.25rem 1.25rem;
  text-align: center;
}

#app-shell #tab-reports.reports-2026 .reports-table-empty-title {
  margin: 0;
  font-size: 0.95rem;
  color: color-mix(in srgb, var(--rpt-ink) 55%, transparent);
}

#app-shell #tab-reports.reports-2026 .portal-page,
#app-shell #tab-reports.reports-2026 .portal-header,
#app-shell #tab-reports.reports-2026 .portal-detail-page {
  display: none;
}

@media (max-width: 640px) {
  #app-shell #tab-reports.reports-2026 .reports-hero-actions {
    margin-left: 0;
    width: 100%;
  }

  #app-shell #tab-reports.reports-2026 .reports-search,
  #app-shell #tab-reports.reports-2026 .reports-search--detail {
    max-width: none;
    flex-basis: 100%;
  }
}
