/* Production dashboard: spacious charcoal surfaces with neutral accents. */
.production-estimate-reference { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 16px 0 0; padding: 12px 0; border-top: 1px solid var(--ui-border); border-bottom: 1px solid var(--ui-border); }
.production-estimate-reference > div { display: grid; align-content: start; gap: 5px; min-width: 0; }
.production-estimate-reference span, .production-estimate-reference small { color: var(--ui-muted); font-size: 12px; line-height: 1.6; }
.production-estimate-reference strong { color: var(--ui-text); font-size: 14px; font-weight: 600; line-height: 1.6; }
.production-estimate-activity > span { color: var(--ui-secondary); font-weight: 500; }
.production-estimate-overview { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 16px 0 10px; }
.production-estimate-overview > div { display: grid; align-content: start; gap: 6px; min-width: 0; }
.production-estimate-overview span { display: flex; align-items: center; gap: 6px; color: var(--ui-muted); font-size: 12px; line-height: 1.5; }
.production-estimate-overview i { width: 8px; height: 8px; flex: 0 0 8px; border-radius: 2px; }
.production-estimate-overview strong { color: var(--ui-text); font-size: 20px; font-weight: 600; line-height: 1.5; font-variant-numeric: tabular-nums; }
.production-estimate-result { margin: 0 0 14px; color: var(--ui-muted); font-size: 12px; line-height: 1.7; }
.production-stats-main .dosage-output-potential { fill: #61af9a; background: #61af9a; }
.production-stats-main .dosage-output-line.dosage-output-potential { fill: none; stroke: #61af9a; stroke-dasharray: 6 4; }
:root[data-theme='light'] .production-stats-main .dosage-output-potential { fill: #24735e; background: #24735e; }
:root[data-theme='light'] .production-stats-main .dosage-output-line.dosage-output-potential { fill: none; stroke: #24735e; }
@media (max-width: 1100px) { .production-estimate-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); } .production-estimate-overview > div:last-child { grid-column: 1 / -1; } }
@media (max-width: 560px) { .production-estimate-reference { grid-template-columns: minmax(0, 1fr); gap: 10px; } }
@media screen {
  :root .ops-app[data-theme] .production-stats-layout {
    --stats-surface: #1a1a1a;
    --stats-tile: #242424;
    --stats-hover: #303030;
    --stats-foreground: #fff;
    --stats-secondary: #b3b3b3;
    --stats-accent: #2b2b2b;
    --stats-accent-text: #ffffff;
    --stats-accent-foreground: #d4d4d8;
    --stats-divider: #ffffff12;
    --ui-panel: var(--stats-tile);
    --ui-input: var(--stats-hover);
    --ui-text: var(--stats-foreground);
    --ui-secondary: #dedede;
    --ui-muted: var(--stats-secondary);
    --ui-accent: var(--stats-accent-foreground);
    width: min(calc(100% - 48px), 1600px);
    margin: 24px auto 48px;
    border-radius: 20px;
    background: var(--stats-surface);
    overflow: hidden;
  }

  :root .ops-app[data-theme='light'] .production-stats-layout {
    --stats-surface: #fff;
    --stats-tile: rgb(255 255 255 / 88%);
    --stats-hover: #eeeeef;
    --stats-foreground: #171717;
    --stats-secondary: #626262;
    --stats-accent: #e8e8e8;
    --stats-accent-text: #ffffff;
    --stats-accent-foreground: #52525b;
    --stats-divider: #00000012;
    --ui-secondary: #404040;
  }

  :root .ops-app[data-theme='goth'] .production-stats-layout {
    --stats-surface: #0e0e0e;
    --stats-tile: #181818;
    --stats-accent: #e0e0e0;
    --stats-accent-text: #111;
    --stats-accent-foreground: #e0e0e0;
  }

  :root .ops-app[data-theme] .production-stats-main {
    --dosage-chart-production: #4f83db;
    --stats-input-background: var(--stats-hover);
    --stats-input-text: var(--stats-foreground);
    --stats-label-text: var(--stats-secondary);
    min-width: 0;
    padding: 28px 32px 40px;
    background: linear-gradient(165deg, rgb(255 255 255 / 3%), transparent 340px), var(--stats-surface);
    color: var(--stats-foreground);
  }

  :root .ops-app[data-theme] .production-stats-main .ops-breadcrumb { margin-bottom: 28px; color: var(--stats-secondary); }
  :root .ops-app[data-theme] .production-stats-heading { gap: 28px; margin-bottom: 16px; }
  :root .ops-app[data-theme] .production-stats-heading .ops-overline { color: var(--stats-accent-foreground); font-size: 11px; font-weight: 700; letter-spacing: 1.8px; }
  :root .ops-app[data-theme] .production-stats-heading h1 { margin-block: 10px; color: var(--stats-foreground); font-size: clamp(28px, 3.2vw, 46px); font-weight: 800; letter-spacing: -1.6px; line-height: 1.15; }
  :root .ops-app[data-theme] .production-stats-heading > div > p { color: var(--stats-secondary); font-size: 13px; line-height: 1.7; }
  :root .ops-app[data-theme] .production-stats-filter { gap: 18px; padding-bottom: 22px; border-bottom: 1px solid var(--stats-divider); }
  :root .ops-app[data-theme] .production-stats-fields { gap: 12px; }
  :root .ops-app[data-theme] .production-stats-field { gap: 8px; font-size: 11px; font-weight: 600; }
  :root .ops-app[data-theme] .production-stats-field input { height: 44px; border-color: #ffffff1a; border-radius: 12px; background: var(--stats-hover); color: var(--stats-foreground); }
  :root .ops-app[data-theme] .production-stats-field input:focus-visible { outline-color: #142e54; border-color: #142e54; }

  :root .ops-app[data-theme] .production-stats-main .ops-button { border-radius: 999px; font-weight: 700; letter-spacing: 0; transition: background-color .15s, border-color .15s; }
  :root .ops-app[data-theme] .production-stats-main .ops-button-secondary { border-color: #454545; background: #242424; color: #e5e5e5; }
  :root .ops-app[data-theme] .production-stats-main .ops-button-secondary:hover:not(:disabled) { border-color: #737373; background: #303030; color: #fff; }
  :root .ops-app[data-theme] .production-stats-filter-actions button[type='submit'] { border-color: #142e54; background: #142e54; color: #fff; padding-inline: 26px; }
  :root .ops-app[data-theme] .production-stats-filter-actions button[type='submit']:hover:not(:disabled) { border-color: #1c3c69; background: #1c3c69; }

  :root .ops-app[data-theme] .production-stats-main .dosage-metrics { gap: 14px; margin-block: 24px; }
  :root .ops-app[data-theme] .production-stats-main .ops-metric-card { min-height: 154px; padding: 22px; border: 1px solid #ffffff12; border-radius: 18px; background: linear-gradient(145deg, rgb(255 255 255 / 3%), transparent 72%), var(--stats-tile); box-shadow: 0 10px 28px rgb(0 0 0 / 14%); transition: background-color .15s, border-color .15s, transform .15s, box-shadow .15s; }
  :root .ops-app[data-theme] .production-stats-main .ops-metric-card:hover { border-color: #505050; background: linear-gradient(145deg, rgb(255 255 255 / 3%), transparent 72%), var(--stats-hover); box-shadow: 0 12px 30px rgb(0 0 0 / 18%); }
  :root .ops-app[data-theme] .production-stats-main .ops-metric-top > span:first-child { color: var(--stats-secondary); font-size: 12px; }
  :root .ops-app[data-theme] .production-stats-main .ops-metric-value { color: var(--stats-foreground); font-size: clamp(24px, 2.2vw, 34px); font-weight: 750; letter-spacing: -1px; }
  :root .ops-app[data-theme] .production-stats-main .ops-metric-foot { color: var(--stats-secondary); font-size: 11px; line-height: 1.6; }
  :root .ops-app[data-theme] .production-stats-main .ops-metric-icon { width: 36px; height: 36px; border: 0; border-radius: 50%; }
  :root .ops-app[data-theme] .production-stats-main :is(.ops-icon-green, .ops-icon-purple, .ops-icon-orange) { color: #d4d4d8; background: rgb(255 255 255 / 8%); }
  :root .ops-app[data-theme] .production-stats-main .ops-icon-blue { color: #93c5fd; background: rgb(30 58 138 / 28%); }

  :root .ops-app[data-theme] .production-start-information { margin: 8px 0 22px; color: var(--stats-secondary); }
  :root .ops-app[data-theme] .production-stats-main .production-stoppages-entry { margin-top: 0; padding: 18px 0 22px; border: 0; border-bottom: 1px solid var(--stats-divider); border-radius: 0; background: transparent; }
  :root .ops-app[data-theme] .production-stats-main .production-stoppages-entry h2 { color: var(--stats-foreground); font-size: 18px; font-weight: 700; }
  :root .ops-app[data-theme] .production-stats-main .production-stoppages-entry p { color: var(--stats-secondary); }

  :root .ops-app[data-theme] .production-stats-main :is(.dosage-charts-grid, .dosage-details-grid) { gap: 18px; margin-top: 24px; }
  :root .ops-app[data-theme] .production-stats-main .dosage-chart-card { padding: 24px; border: 1px solid #ffffff12; border-radius: 18px; background: linear-gradient(145deg, rgb(255 255 255 / 2%), transparent 60%), var(--stats-tile); box-shadow: 0 10px 28px rgb(0 0 0 / 14%); }
  :root .ops-app[data-theme] .production-stats-main .dosage-chart-heading h2 { color: var(--stats-foreground); font-size: 18px; font-weight: 700; letter-spacing: -.3px; }
  :root .ops-app[data-theme] .production-stats-main .dosage-chart-heading p { margin-top: 8px; color: var(--stats-secondary); font-size: 12px; }
  :root .ops-app[data-theme] .production-stats-main :is(.dosage-output-legend, .dosage-data-note, .dosage-chart-empty) { color: var(--stats-secondary); }
  :root .ops-app[data-theme] .production-stats-main .dosage-stoppage-row { padding: 12px 8px; border-radius: 6px; color: var(--stats-secondary); }
  :root .ops-app[data-theme] .production-stats-main .dosage-stoppage-row:hover { background: var(--stats-hover); }
  :root .ops-app[data-theme] .production-stats-main .dosage-stoppage-row strong { color: var(--stats-foreground); }
  :root .ops-app[data-theme] .production-stats-main > .dosage-data-note:last-child { margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--stats-divider); font-size: 11px; line-height: 1.8; }

  @media (max-width: 1100px) {
    :root .ops-app[data-theme] .production-stats-main .dosage-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  }
  @media (max-width: 700px) {
    :root .ops-app[data-theme] .production-stats-layout { width: calc(100% - 20px); margin-block: 12px 28px; }
    :root .ops-app[data-theme] .production-stats-main { padding: 22px 16px 28px; }
    :root .ops-app[data-theme] .production-stats-heading { gap: 24px; }
    :root .ops-app[data-theme] .production-stats-heading h1 { letter-spacing: -1px; }
    :root .ops-app[data-theme] .production-stats-main .dosage-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    :root .ops-app[data-theme] .production-stats-main .ops-metric-card { min-height: 140px; padding: 16px; }
    :root .ops-app[data-theme] .production-stats-main .dosage-chart-card { padding: 18px; }
    :root .ops-app[data-theme] .production-start-information .ops-button { width: 100%; }
    :root .ops-app[data-theme] .production-stats-main :is(.dosage-charts-grid, .dosage-details-grid) { grid-template-columns: minmax(0, 1fr); }
  }
  @media (prefers-reduced-motion: reduce) {
    :root .ops-app[data-theme] .production-stats-main :is(.ops-button, .ops-metric-card) { transition: none; }
  }
}

/* Keep the batches report visually connected to the factory statistics page. */
@media screen {
  :root .ops-app[data-theme] .production-batches-report {
    --stats-surface: #1a1a1a;
    --stats-tile: #242424;
    --stats-hover: #303030;
    --stats-foreground: #fff;
    --stats-secondary: #b3b3b3;
    --stats-accent: #2b2b2b;
    --stats-accent-text: #ffffff;
    --stats-accent-foreground: #d4d4d8;
    --stats-divider: #ffffff12;
    --ui-panel: var(--stats-tile);
    --ui-input: var(--stats-hover);
    --ui-text: var(--stats-foreground);
    --ui-secondary: #dedede;
    --ui-muted: var(--stats-secondary);
    --ui-accent: var(--stats-accent-foreground);
    box-sizing: border-box;
    width: min(calc(100% - 48px), 1600px);
    margin: 24px auto 48px;
    padding: 28px 32px 40px;
    overflow: hidden;
    border-radius: 14px;
    color: var(--stats-foreground);
    background: linear-gradient(165deg, rgb(255 255 255 / 3%), transparent 340px), var(--stats-surface);
  }

  :root .ops-app[data-theme='light'] .production-batches-report {
    --stats-surface: #fff;
    --stats-tile: rgb(255 255 255 / 88%);
    --stats-hover: #eeeeef;
    --stats-foreground: #171717;
    --stats-secondary: #626262;
    --stats-accent: #e8e8e8;
    --stats-accent-text: #ffffff;
    --stats-accent-foreground: #52525b;
    --stats-divider: #00000012;
    --ui-secondary: #404040;
  }

  :root .ops-app[data-theme='goth'] .production-batches-report {
    --stats-surface: #0e0e0e;
    --stats-tile: #181818;
    --stats-accent: #142e54;
    --stats-accent-text: #ffffff;
    --stats-accent-foreground: #93c5fd;
  }

  :root .ops-app[data-theme] .production-batches-report .ops-breadcrumb { margin-bottom: 28px; color: var(--stats-secondary); }
  :root .ops-app[data-theme] .production-batches-report .erp-report-heading { gap: 28px; margin-bottom: 16px; }
  :root .ops-app[data-theme] .production-batches-report .erp-report-heading .ops-overline { color: var(--stats-accent-foreground); font-size: 11px; font-weight: 700; letter-spacing: 1.8px; }
  :root .ops-app[data-theme] .production-batches-report .erp-report-heading h1 { margin-block: 10px; color: var(--stats-foreground); font-size: clamp(28px, 3.2vw, 46px); font-weight: 800; letter-spacing: -1.6px; line-height: 1.15; }
  :root .ops-app[data-theme] .production-batches-report .erp-report-heading p,
  :root .ops-app[data-theme] .production-batches-report > .erp-muted { color: var(--stats-secondary); font-size: 13px; line-height: 1.7; }
  :root .ops-app[data-theme] .production-batches-report .erp-filters { gap: 18px; padding: 0 0 22px; border: 0; border-bottom: 1px solid var(--stats-divider); border-radius: 0; background: transparent; }
  :root .ops-app[data-theme] .production-batches-report .erp-filters label { gap: 8px; font-size: 11px; font-weight: 600; }
  :root .ops-app[data-theme] .production-batches-report .erp-filters input { min-width: min(320px, 100%); height: 44px; border-color: transparent; border-radius: 8px; background: var(--stats-hover); color: var(--stats-foreground); color-scheme: inherit; }
  :root .ops-app[data-theme] .production-batches-report .erp-filters input:focus-visible { outline-color: var(--stats-accent-foreground); border-color: var(--stats-accent-foreground); }
  :root .ops-app[data-theme] .production-batches-report .ops-button { border-radius: 999px; font-weight: 700; letter-spacing: 0; transition: background-color .15s, border-color .15s; }
  :root .ops-app[data-theme] .production-batches-report .ops-button-secondary { border-color: #80808060; background: transparent; color: var(--stats-foreground); }
  :root .ops-app[data-theme] .production-batches-report .ops-button-secondary:hover:not(:disabled) { border-color: var(--stats-foreground); background: var(--stats-hover); }
  :root .ops-app[data-theme] .production-batches-report .erp-panel { border: 0; border-radius: 12px; background: var(--stats-tile); box-shadow: none; }
  :root .ops-app[data-theme] .production-batches-report .erp-metrics { gap: 14px; margin-block: 24px; }
  :root .ops-app[data-theme] .production-batches-report .erp-metrics article { border: 0; border-radius: 10px; background: var(--stats-tile); box-shadow: none; }
  :root .ops-app[data-theme] .production-batches-report .erp-metrics article > span,
  :root .ops-app[data-theme] .production-batches-report .erp-metrics article > small { color: var(--stats-secondary); }
  :root .ops-app[data-theme] .production-batches-report .erp-metrics article > strong { color: var(--stats-foreground); }
  :root .ops-app[data-theme] .production-batches-report .erp-table-scroll { border-color: var(--stats-divider); }
  :root .ops-app[data-theme] .production-batches-report .erp-table th { background: var(--stats-hover); }
  :root .ops-app[data-theme] .production-batches-report .erp-table td { border-color: var(--stats-divider); }

  @media (max-width: 700px) {
    :root .ops-app[data-theme] .production-batches-report { width: calc(100% - 20px); margin-block: 12px 28px; padding: 22px 16px 28px; }
    :root .ops-app[data-theme] .production-batches-report .erp-filters label,
    :root .ops-app[data-theme] .production-batches-report .erp-filters input { width: 100%; min-width: 0; }
    :root .ops-app[data-theme] .production-batches-report .erp-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  }

  @media (prefers-reduced-motion: reduce) {
    :root .ops-app[data-theme] .production-batches-report .ops-button { transition: none; }
  }
}
.production-timeline-page .production-timeline-heading {
  align-items: flex-end;
  gap: 24px;
}

.production-timeline-page .production-stats-filter {
  flex: 0 1 auto;
}

.production-timeline-page .production-timeline-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 22px;
}

.production-process-map {
  margin-top: 22px;
  padding: 24px;
  overflow: hidden;
  border: 1px solid var(--stats-divider);
  border-radius: 14px;
  background: linear-gradient(145deg, color-mix(in srgb, var(--stats-accent) 34%, var(--stats-tile)), var(--stats-tile) 58%);
}

.production-process-map-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}

.production-process-map-header h2 {
  margin: 6px 0;
  color: var(--stats-foreground);
  font-size: 20px;
  letter-spacing: -.4px;
}

.production-process-map-header p {
  margin: 0;
  color: var(--stats-secondary);
  font-size: 12px;
}

.production-process-map-header .ops-overline,
.production-process-observation-kicker {
  color: var(--stats-accent-foreground);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
}

.production-process-map-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 250px;
  gap: 18px;
  align-items: stretch;
}

.production-process-map-canvas {
  min-width: 0;
  padding: 18px 12px 14px;
  overflow-x: auto;
  border: 1px solid var(--stats-divider);
  border-radius: 12px;
  background: rgb(0 0 0 / 10%);
}

.production-process-stages {
  display: flex;
  min-width: max-content;
  align-items: center;
  justify-content: center;
  gap: 0;
}

.production-process-node {
  position: relative;
  display: grid;
  width: 176px;
  min-height: 150px;
  flex: 0 0 176px;
  align-content: start;
  gap: 8px;
  padding: 15px;
  border: 1px solid var(--stats-divider);
  border-radius: 11px;
  color: var(--stats-secondary);
  text-align: left;
  background: linear-gradient(150deg, var(--stats-hover), var(--stats-tile));
  cursor: grab;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.production-process-node:hover { transform: translateY(-3px); }
.production-process-node:active { cursor: grabbing; }
.production-process-node.is-selected {
  border-color: var(--stats-accent-foreground);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--stats-accent-foreground) 20%, transparent), 0 12px 28px rgb(0 0 0 / 18%);
}

.production-process-node-index {
  display: grid;
  width: 25px;
  height: 25px;
  place-items: center;
  border-radius: 7px;
  color: var(--stats-accent-foreground);
  background: color-mix(in srgb, var(--stats-accent) 65%, var(--stats-tile));
  font-size: 10px;
  font-weight: 700;
}

.production-process-node small {
  color: var(--stats-secondary);
  font-size: 10px;
}

.production-process-node strong {
  color: var(--stats-foreground);
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}

.production-process-node > span:last-child {
  display: -webkit-box;
  overflow: hidden;
  color: var(--stats-secondary);
  font-size: 10px;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.production-process-connector {
  position: relative;
  width: 26px;
  height: 1px;
  flex: 0 0 26px;
  background: var(--stats-accent-foreground);
  opacity: .65;
}

.production-process-connector::after {
  position: absolute;
  top: -3px;
  right: 0;
  width: 6px;
  height: 6px;
  transform: rotate(45deg);
  border-top: 1px solid var(--stats-accent-foreground);
  border-right: 1px solid var(--stats-accent-foreground);
  content: '';
}

.production-process-observation {
  display: flex;
  min-height: 190px;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding: 18px;
  border: 1px dashed color-mix(in srgb, var(--stats-accent-foreground) 56%, var(--stats-divider));
  border-radius: 12px;
  background: color-mix(in srgb, var(--stats-accent) 22%, var(--stats-tile));
  transition: background 150ms ease, border-color 150ms ease;
}

.production-process-observation-icon { margin-top: 16px; color: var(--stats-accent-foreground); }
.production-process-observation h3 { margin: 8px 0 3px; color: var(--stats-foreground); font-size: 14px; }
.production-process-observation > strong { color: var(--stats-accent-foreground); font-size: 19px; font-variant-numeric: tabular-nums; }
.production-process-observation p { margin: 8px 0 12px; color: var(--stats-secondary); font-size: 11px; line-height: 1.55; }
.production-process-observation > small { color: var(--stats-secondary); font-size: 9px; line-height: 1.5; }
.production-process-map-empty { padding: 28px 12px; color: var(--stats-secondary); text-align: center; }

.production-map-period {
  flex: 0 0 auto;
  padding: 7px 10px;
  border: 1px solid var(--stats-divider);
  border-radius: 7px;
  color: var(--stats-secondary);
  background: var(--stats-hover);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}

.production-process-map-body { grid-template-columns: minmax(0, 1fr) 260px; }
.production-process-orders { display: grid; min-width: 0; gap: 13px; }

.production-process-order {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--stats-divider);
  border-radius: 12px;
  background: color-mix(in srgb, var(--stats-tile) 88%, #000);
  transition: border-color 150ms ease, background 150ms ease;
}

.production-process-order:hover {
  border-color: color-mix(in srgb, var(--stats-accent-foreground) 48%, var(--stats-divider));
  background: color-mix(in srgb, var(--stats-tile) 75%, var(--stats-accent));
}

.production-process-order.is-located {
  border-color: var(--stats-accent-foreground);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--stats-accent-foreground) 24%, transparent), 0 16px 38px rgb(0 0 0 / 24%);
}

.production-process-locator {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: -6px 0 16px;
}

.production-process-locator label {
  display: flex;
  min-width: min(100%, 360px);
  min-height: 40px;
  align-items: center;
  gap: 9px;
  padding: 0 12px;
  border: 1px solid var(--stats-divider);
  border-radius: 999px;
  color: var(--stats-secondary);
  background: var(--stats-hover);
}

.production-process-locator label:focus-within {
  border-color: var(--stats-accent-foreground);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--stats-accent-foreground) 16%, transparent);
}

.production-process-locator input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: var(--stats-foreground);
  background: transparent;
  font: inherit;
  font-size: 12px;
}

.production-process-locator > span {
  color: var(--stats-secondary);
  font-size: 10px;
}

.production-process-locator .ops-button { min-height: 38px; padding-inline: 17px; border-radius: 999px; }

.production-process-order-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
}

.production-process-order-heading > div { min-width: 0; }
.production-process-order-kicker { color: var(--stats-accent-foreground); font-size: 9px; font-weight: 700; letter-spacing: 1.25px; }
.production-process-order-heading h3 { margin: 3px 0; color: var(--stats-foreground); font-size: 16px; }
.production-process-order-heading small { display: block; overflow-wrap: anywhere; color: var(--stats-secondary); font-size: 10px; }

.production-process-status {
  flex: 0 0 auto;
  padding: 5px 9px;
  border: 1px solid var(--stats-divider);
  border-radius: 999px;
  color: var(--stats-secondary);
  background: var(--stats-hover);
  font-size: 10px;
  font-weight: 600;
}

.production-process-status.is-concluida { border-color: #142e5488; color: var(--stats-accent-foreground); background: color-mix(in srgb, var(--stats-accent) 38%, var(--stats-tile)); }
.production-process-status.is-sem_dosagem,
.production-process-status.is-sem_pesagem,
.production-process-status.is-pesagem_anterior_a_dosagem { border-color: #d5b08055; color: #d5b080; background: rgb(213 176 128 / 8%); }

.production-process-order .production-process-map-canvas {
  padding: 0;
  overflow: auto hidden;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.production-process-order .production-process-stages { justify-content: flex-start; }
.production-process-order .production-process-node { width: 148px; min-height: 132px; flex-basis: 148px; padding: 12px; }
.production-process-order .production-process-connector { width: 20px; flex-basis: 20px; }
.production-process-order .production-process-node strong { font-size: 13px; }
.production-process-observation { position: sticky; top: 92px; align-self: start; min-height: 230px; }
.production-process-observation > small:first-of-type { margin-top: 7px; color: var(--stats-secondary); font-size: 10px; }

@media screen and (max-width: 920px) {
  .production-timeline-page .production-timeline-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .production-timeline-page .production-stats-filter {
    width: 100%;
  }

  .production-timeline-page .production-timeline-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .production-process-map-body { grid-template-columns: minmax(0, 1fr); }
  .production-process-observation { position: static; min-height: 0; }
}

@media screen and (max-width: 560px) {
  .production-timeline-page .production-timeline-metrics {
    grid-template-columns: minmax(0, 1fr);
  }

  .production-process-map { padding: 17px; }
  .production-process-map-header { align-items: stretch; flex-direction: column; }
  .production-process-locator { align-items: stretch; flex-direction: column; }
  .production-process-locator label { width: auto; }
  .production-process-locator > span { text-align: center; }
}
@media screen {
  :root #root .ops-app.ops-workspace .production-stats-layout { overflow: visible; }
  :root #root .ops-app.ops-workspace .production-stats-heading { align-items: flex-start; gap: 22px; }
  :root #root .ops-app.ops-workspace .production-stats-filter {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 14px 18px;
    padding: 18px;
    border: 1px solid var(--ui-border);
    border-radius: 16px;
    background: linear-gradient(145deg, color-mix(in srgb, var(--workspace-accent) 7%, var(--ui-panel)), var(--ui-panel) 65%);
    box-shadow: 0 10px 26px rgb(0 0 0 / 10%);
  }
  :root #root .ops-app.ops-workspace .production-stats-filter-heading { display: grid; grid-column: 1 / -1; gap: 4px; }
  :root #root .ops-app.ops-workspace .production-stats-filter-heading strong { color: var(--ui-text); font-size: 13px; }
  :root #root .ops-app.ops-workspace .production-stats-filter-heading span { color: var(--ui-muted); font-size: 11px; }
  :root #root .ops-app.ops-workspace .production-stats-filter-actions { align-self: end; }
  :root #root .ops-app.ops-workspace .production-stats-filter-actions button[type='submit'] { border-color: #3d6f9f; background: #3d6f9f; color: #fff; }
  :root #root .ops-app.ops-workspace .production-stats-filter-actions button[type='submit']:hover:not(:disabled) { border-color: #4d82b6; background: #4d82b6; }
  :root #root .ops-app.ops-workspace .production-stats-section-heading,
  :root #root .ops-app.ops-workspace .production-stats-tools-heading { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin: 26px 0 12px; }
  :root #root .ops-app.ops-workspace .production-stats-section-heading > div,
  :root #root .ops-app.ops-workspace .production-stats-tools-heading > div { display: grid; gap: 4px; }
  :root #root .ops-app.ops-workspace .production-stats-section-heading span,
  :root #root .ops-app.ops-workspace .production-stats-tools-heading span { color: var(--workspace-accent); font-size: 9px; font-weight: 750; letter-spacing: .14em; }
  :root #root .ops-app.ops-workspace .production-stats-section-heading h2,
  :root #root .ops-app.ops-workspace .production-stats-tools-heading h2 { margin: 0; color: var(--ui-text); font-size: 17px; font-weight: 650; letter-spacing: -.3px; }
  :root #root .ops-app.ops-workspace .production-stats-section-heading p,
  :root #root .ops-app.ops-workspace .production-stats-tools-heading p { margin: 0; color: var(--ui-muted); font-size: 11px; }
  :root #root .ops-app.ops-workspace .dosage-metrics { margin-top: 0; }
  :root #root .ops-app.ops-workspace .production-stats-main .ops-metric-card {
    border-color: color-mix(in srgb, var(--workspace-accent) 20%, var(--ui-border));
    background: linear-gradient(145deg, color-mix(in srgb, var(--workspace-accent) 7%, var(--ui-panel)), var(--ui-panel) 58%);
    box-shadow: 0 12px 28px rgb(0 0 0 / 12%);
  }
  :root #root .ops-app.ops-workspace .production-stats-main .ops-metric-top > span:first-child { color: var(--ui-muted); font-size: 11px; font-weight: 650; }
  :root #root .ops-app.ops-workspace .production-stats-main .ops-metric-foot { max-width: 27ch; font-size: 10px; line-height: 1.55; }
  :root #root .ops-app.ops-workspace .production-stats-main .dosage-chart-card { border-color: var(--ui-border); background: linear-gradient(145deg, color-mix(in srgb, var(--workspace-accent) 5%, var(--ui-panel)), var(--ui-panel) 62%); }
  :root #root .ops-app.ops-workspace .production-stats-main .production-start-information { gap: 10px; margin: 0; padding: 14px; border: 1px solid var(--ui-border); border-radius: 14px; background: color-mix(in srgb, var(--ui-panel) 82%, transparent); }
  :root #root .ops-app.ops-workspace .production-stats-main .production-start-information .ops-button { border-color: var(--ui-border-strong); background: var(--ui-panel); color: var(--ui-text); }
  :root #root .ops-app.ops-workspace .production-stats-main .production-start-information .ops-button:hover:not(:disabled) { border-color: var(--workspace-accent); background: var(--ui-hover); }
  :root #root .ops-app.ops-workspace .production-stats-main .production-stoppages-entry { margin-top: 20px; padding: 18px; border: 1px solid var(--ui-border); border-radius: 14px; background: linear-gradient(120deg, color-mix(in srgb, var(--workspace-accent) 8%, var(--ui-panel)), var(--ui-panel)); }
  @media (max-width: 850px) {
    :root #root .ops-app.ops-workspace .production-stats-filter { grid-template-columns: minmax(0, 1fr); }
    :root #root .ops-app.ops-workspace .production-stats-filter-actions { justify-content: flex-start; }
  }
  @media (max-width: 560px) {
    :root #root .ops-app.ops-workspace :is(.production-stats-section-heading, .production-stats-tools-heading) { align-items: flex-start; flex-direction: column; }
    :root #root .ops-app.ops-workspace .production-stats-main .production-start-information .ops-button { width: 100%; justify-content: flex-start; }
  }
}
