/* Cross-page visual calibration only. This file does not define data, workflow, navigation, or print rules. */

@media screen {
  /* Typography scale: page 32px, section 22px, card 18px, body 16px, caption 13–14px. */
  .workspace .topbar h1 {
    font-size: var(--erp-font-size-2xl);
    font-weight: var(--erp-font-weight-semibold);
  }

  :is(.panel-title, .receiving-section-head, .reconcile-section-head, .smart-assistant-workspace-heading) h2 {
    font-size: 22px;
    font-weight: var(--erp-font-weight-semibold);
    line-height: var(--erp-line-height-tight);
  }

  :is(.task-card, .work-queue-card, .erp-list-row) strong:first-child,
  .work-queue-copy strong {
    font-size: 18px;
    font-weight: var(--erp-font-weight-semibold);
  }

  :is(.panel-title, .receiving-section-head, .reconcile-section-head) p,
  :is(.panel-title, .receiving-section-head, .reconcile-section-head) small,
  .erp-list-cell small,
  .work-queue-copy small {
    font-size: var(--erp-font-size-sm);
    font-weight: var(--erp-font-weight-regular);
  }

  /* Width patterns: focused workflow, standard workbench, and wide list/table work. */
  .smart-assistant-workspace {
    max-width: var(--erp-content-max-width-focused);
  }

  :is(.work-queue-workspace, .receiving-workspace) {
    max-width: var(--erp-content-max-width-standard);
  }

  :is(.reconcile-workspace, .master-grid) {
    max-width: var(--erp-content-max-width-wide);
  }

  /* Existing page headers and company controls share one vertical rhythm. */
  .topbar + .company-grid {
    margin-top: 0;
  }

  .company-grid {
    align-items: stretch;
    margin-bottom: var(--erp-section-gap);
  }

  .company-tile {
    min-height: 56px;
    padding: var(--erp-space-2) var(--erp-space-3);
  }

  .company-tile span {
    width: 28px;
    height: 28px;
    border-radius: var(--erp-radius-sm);
  }

  .company-tile strong {
    font-weight: var(--erp-font-weight-semibold);
  }

  .company-tile small {
    font-size: 13px;
    font-weight: var(--erp-font-weight-regular);
  }

  /* List rows become one quiet Surface with dividers, instead of a card inside a card. */
  .erp-list-content:has(> .erp-list-row) {
    gap: 0;
    overflow: hidden;
    border: var(--erp-border-width) var(--erp-border-style) var(--erp-border);
    border-radius: var(--erp-radius-lg);
    background: var(--erp-surface);
  }

  .erp-list-content:has(> .erp-list-row) > .erp-list-row {
    border: 0;
    border-bottom: var(--erp-border-width) var(--erp-border-style) var(--erp-border);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }

  .erp-list-content:has(> .erp-list-row) > .erp-list-row:last-child {
    border-bottom: 0;
  }

  .erp-list-content:has(> .erp-list-row) > .erp-list-row:hover {
    border-color: var(--erp-border);
    background: var(--erp-surface-hover);
    box-shadow: none;
  }

  .erp-list-content:has(> .erp-list-row) > .erp-list-row.is-selected,
  .erp-list-content:has(> .erp-list-row) > .erp-list-row[aria-selected="true"] {
    background: var(--erp-surface-selected);
  }

  /* Disabled work stays informative, never interactive. */
  .work-queue-card.is-disabled {
    cursor: default;
    color: var(--erp-text-muted);
    opacity: .82;
  }

  .work-queue-card.is-disabled:hover {
    border-color: var(--erp-border);
    border-left-color: var(--work-queue-accent);
    background: var(--erp-surface-muted);
    box-shadow: none;
    transform: none;
  }
}

@media screen and (max-width: 760px) {
  .workspace .topbar h1 { font-size: var(--erp-font-size-xl); }

  :is(.panel-title, .receiving-section-head, .reconcile-section-head, .smart-assistant-workspace-heading) h2 {
    font-size: 22px;
  }

  .company-tile {
    min-height: 52px;
    padding-inline: var(--erp-space-2);
  }
}
