:root {
  --brand-blue: #2379b2;
  --brand-lime: #c8f17a;
  --text-primary: #142b43;
  --text-secondary: #425a70;
  --text-muted: #5d7084;
  --surface: #fff;
  --line: #dce5ed;
  font-family:
    Inter,
    Segoe UI,
    Arial,
    sans-serif;
  color: #14213d;
  background: #f5f9fc;
  font-synthesis: none;
  font-size: 14px;
  line-height: 1.5;
}
.assistant {
  margin-top: 24px;
}
.assistant .panel {
  margin-top: 12px;
}
.plain-answer {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.event-preview {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid #e8edf5;
}
.event-preview small,
td small {
  display: block;
  color: #62718a;
}
.sales-spark {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}
.sales-spark div {
  padding: 10px;
  border: 1px solid #e8edf5;
  border-radius: 8px;
}
.sales-spark span,
.sales-spark strong {
  display: block;
}
.product-choices {
  max-height: 240px;
  overflow-y: auto;
  margin: 10px 0;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a.button {
  border: 1px solid transparent;
  background: var(--brand-blue);
  color: white;
  border-radius: 9px;
  min-height: 40px;
  padding: 9px 15px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
button:hover,
a.button:hover {
  filter: brightness(0.96);
}
button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
button[aria-busy="true"] {
  cursor: progress;
}
.ui-icon {
  flex-shrink: 0;
  vertical-align: middle;
}
.button-spinner {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: button-spin 0.8s linear infinite;
}
@keyframes button-spin {
  to {
    transform: rotate(360deg);
  }
}
.skip-link {
  position: fixed;
  top: -100px;
  left: 16px;
  z-index: 100;
  padding: 12px 18px;
  background: white;
  border: 2px solid var(--brand-blue);
  border-radius: 8px;
}
.skip-link:focus {
  top: 12px;
}
.global-message .notice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.icon-button {
  padding: 8px;
  min-width: 36px;
  flex-shrink: 0;
}
.panel > button + button {
  margin-left: 8px;
}
.nav-backdrop {
  display: none;
}
.sidebar-close {
  position: absolute;
  right: 12px;
  top: 12px;
  padding: 8px;
}
#main-content:focus {
  outline: none;
}
@media (prefers-reduced-motion: reduce) {
  .button-spinner {
    animation: none;
  }
  .sidebar {
    transition: none !important;
  }
}
.secondary {
  background: #fff !important;
  color: #233754 !important;
  border-color: #dbe2ee !important;
}
button.link {
  background: none;
  color: #2a83bf;
  padding: 2px;
  min-height: 28px;
}
input,
select,
textarea {
  width: 100%;
  min-height: 40px;
  border: 1px solid #d9e1ed;
  border-radius: 8px;
  padding: 8px 12px;
  background: #fff;
  color: #14213d;
}
input:focus,
select:focus,
button:focus-visible,
a:focus-visible {
  outline: 3px solid #adc8ff;
  outline-offset: 2px;
}
input[type="checkbox"] {
  width: 17px;
  height: 17px;
  min-height: 17px;
  accent-color: #2a83bf;
}
input[type="file"] {
  padding: 6px;
}
select[multiple] {
  min-height: 104px;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font-size: 28px;
  letter-spacing: -0.35px;
  line-height: 1.2;
  margin-bottom: 0;
}
h2 {
  font-size: 17px;
  margin-bottom: 15px;
}
h3 {
  font-size: 15px;
}
.logo {
  font-weight: 900;
  font-size: 23px;
  letter-spacing: -1px;
  color: white;
  background: #3b94cd;
  border-radius: 11px;
  padding: 10px 12px;
  width: fit-content;
  white-space: nowrap;
}
.logo span {
  color: var(--brand-lime);
  margin-left: 3px;
  font-weight: 700;
}
.sidebar {
  width: 224px;
  background: #e5f2fb;
  position: fixed;
  inset: 0 auto 0 0;
  color: #30536c;
  padding: 28px 18px;
  z-index: 20;
  display: flex;
  flex-direction: column;
}
.brand-caption {
  font-size: 12px;
  letter-spacing: 0;
  margin: 8px 0 24px;
  color: #53728a;
}
.sidebar nav {
  display: grid;
  gap: 4px;
  overflow-y: auto;
  min-height: 0;
  flex: 1;
  align-content: start;
}
.sidebar nav button {
  justify-content: flex-start;
  gap: 12px;
  background: none;
  color: #355770;
  padding: 10px 12px;
  font-size: 13px;
  font-weight: 500;
  min-height: 42px;
}
.sidebar nav button span {
  font-size: 19px;
  width: 22px;
}
.sidebar nav button.selected {
  background: #fff;
  color: #22678f;
  box-shadow: 0 3px 12px #2f7cad12;
  border-color: #d2e8f7;
}
.sidebar-bottom {
  margin-top: auto;
  padding-top: 24px;
  font-size: 12px;
  flex-shrink: 0;
}
.sidebar-bottom small {
  display: block;
  margin: 8px 0;
  color: #5e7b91;
}
.live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #c8f17a;
  display: inline-block;
  margin-right: 5px;
}
.workspace {
  margin-left: 224px;
  min-width: 0;
}
header {
  height: 76px;
  border-bottom: 1px solid #e3e9f3;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  gap: 14px;
}
.breadcrumb {
  color: #6f7c94;
  font-size: 13px;
}
.breadcrumb span {
  margin: 0 12px;
  color: #b1b9c8;
}
.user {
  display: flex;
  align-items: center;
  gap: 17px;
}
.user > span {
  font-weight: 600;
}
.user small {
  display: block;
  font-weight: 400;
  color: var(--text-muted);
  font-size: 12px;
}
.user button {
  min-height: 34px;
  font-size: 12px;
  padding: 6px 10px;
}
.content {
  padding: 28px 32px;
  max-width: 1800px;
  margin: auto;
}
.page-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 25px;
  gap: 16px;
}
.eyebrow {
  font-size: 12px;
  letter-spacing: 1.7px;
  color: #8290a8;
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
}
.environment {
  font-size: 12px;
  color: #7a879d;
  background: #edf1f8;
  border-radius: 6px;
  padding: 6px 10px;
}
.filters {
  display: grid;
  grid-template-columns: repeat(5, minmax(110px, 1fr));
  gap: 12px;
  margin-bottom: 15px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0 0 15px;
  min-width: 0;
}
.field > span {
  font-size: 12px;
  color: #60708a;
  font-weight: 500;
}
.filters .field {
  margin: 0;
}
.toolbar,
.inline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 15px 0;
}
.toolbar {
  margin-bottom: 22px;
}
.inline .field {
  margin: 0;
}
.panel {
  background: white;
  border: 1px solid #e3e9f3;
  border-radius: 14px;
  padding: 21px 23px;
  margin-bottom: 20px;
  box-shadow: 0 3px 12px #173c7710;
  min-width: 0;
}
.panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.panel-title h2 {
  margin: 0 0 17px;
}
.panel-title > span {
  font-size: 12px;
}
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 8px 0 20px;
}
.kpi {
  border: 1px solid #e3e9f3;
  background: #fff;
  border-radius: 14px;
  padding: 22px 20px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.kpi > span {
  font-size: 12px;
  color: #687b96;
}
.kpi strong {
  font-size: 28px;
  letter-spacing: -1px;
  overflow-wrap: anywhere;
}
.kpi strong small {
  font-size: 18px;
}
.kpi > small {
  font-size: 12px;
  color: #8b97a9;
}
.split {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 20px;
}
.notice {
  border: 1px solid #d8e6ff;
  background: #eef5ff;
  color: #305280;
  padding: 13px 16px;
  border-radius: 10px;
  font-size: 13px;
  margin: 15px 0;
}
.notice p:last-child {
  margin-bottom: 0;
}
.notice.error {
  color: #b62c3a;
  border-color: #f4ccd0;
  background: #fff5f5;
}
.notice.warning {
  color: #805b1f;
  background: #fff9e9;
  border-color: #f2dfa8;
}
.muted {
  color: var(--text-muted);
  font-size: 12px;
}
.empty {
  padding: 36px 20px;
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
}
.table-wrap {
  overflow: auto;
  width: 100%;
  max-height: 620px;
  position: relative;
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 13px;
  white-space: nowrap;
}
thead {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f4f7fb;
}
th {
  padding: 0 10px;
  border-bottom: 1px solid #e1e8f3;
  color: var(--text-muted);
  font-size: 12px;
}
button.sort {
  font-size: 12px;
  color: var(--text-muted);
  background: transparent;
  padding: 12px 0;
  font-weight: 600;
  min-height: 40px;
}
td {
  padding: 12px 12px;
  border-bottom: 1px solid #edf1f7;
  max-width: 420px;
  overflow: hidden;
  text-overflow: ellipsis;
}
tbody tr:hover {
  background: #f8faff;
}
.columns {
  font-size: 12px;
  color: var(--text-muted);
  margin: 0 0 8px;
  text-align: right;
}
.columns summary {
  cursor: pointer;
}
.columns .inline {
  text-align: left;
}
.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 15px;
  font-size: 12px;
  color: var(--text-muted);
}
.pagination button {
  min-height: 32px;
  padding: 5px 12px;
  font-size: 12px;
}
.badge {
  display: inline-block;
  background: #edf1f8;
  color: #697d99;
  border-radius: 5px;
  padding: 4px 8px;
  font-size: 12px;
  white-space: normal;
}
.badge.active,
.badge.succeeded,
.badge.confirmed,
.badge.paid,
.badge.calculated {
  background: #eaf5e2;
  color: #437031;
}
.badge.failed,
.badge.error,
.badge.overdue,
.badge.conflict {
  background: #fff0f0;
  color: #ae3745;
}
.badge.pending,
.badge.running,
.badge.submitted,
.badge.partial,
.badge.needs_data {
  background: #fff5df;
  color: #94681f;
}
.badge.approved {
  background: #e8f0ff;
  color: #2a83bf;
}
.source-banner {
  background: #fff;
  border: 1px solid #e1e8f3;
  border-radius: 14px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  padding: 24px;
  margin-bottom: 22px;
}
.source-banner h2 {
  margin: 10px 0 4px;
}
.source-banner p {
  font-size: 12px;
  color: #8290a5;
  margin: 0 0 10px;
}
.source-banner small {
  font-size: 12px;
  color: #7b8ba3;
}
.form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 17px;
}
.form-grid.compact {
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  align-items: center;
  border-bottom: 1px solid #e6ebf2;
  padding: 12px 0;
}
.check {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 12px 0;
  font-size: 12px;
  color: #536782;
}
.check input {
  flex-shrink: 0;
}
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 23px;
  border-bottom: 1px solid #e0e6f1;
  padding-bottom: 10px;
}
.tabs button {
  background: none;
  color: #6f7e97;
  font-size: 12px;
  min-height: 34px;
}
.tabs button.selected {
  background: #e9f0ff;
  color: #2a83bf;
}
.bars > div {
  margin: 12px 0 18px;
}
.bars > div > div {
  display: flex;
  gap: 15px;
  justify-content: space-between;
  font-size: 12px;
  margin-bottom: 8px;
}
.bars span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.bars strong {
  white-space: nowrap;
  font-weight: 600;
}
.bars svg {
  display: block;
  width: 100%;
  height: 7px;
  fill: #2a83bf;
}
.bars .bar-bg {
  fill: #edf2fc;
}
.stat-line {
  display: flex;
  justify-content: space-between;
  border-bottom: 1px solid #edf1f6;
  padding: 13px 0;
}
.stat-line strong {
  font-size: 20px;
}
.tag {
  padding: 7px 10px;
  background: #f0f5ff;
  color: #34598e;
  font-size: 12px;
  border-radius: 7px;
}
details > summary {
  cursor: pointer;
  color: #71839c;
  font-size: 12px;
  padding: 6px 0;
}
code {
  overflow-wrap: anywhere;
}
.ocr-text {
  white-space: pre-wrap;
  max-height: 320px;
  overflow: auto;
  background: #f4f6fa;
  padding: 15px;
  border-radius: 9px;
  font-family: Consolas, monospace;
  font-size: 12px;
}
.line-list {
  margin-bottom: 15px;
}
.order-line {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border: 1px solid #e1e7f1;
  background: #fafcff;
  border-radius: 10px;
  padding: 13px;
  margin-bottom: 11px;
}
.line-number {
  padding-top: 25px;
  color: #9aa8bd;
}
.line-fields {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 12px;
  flex: 1;
}
.order-line > button {
  margin-top: 24px;
  min-width: 32px;
}
.line-fields .field {
  margin-bottom: 8px;
}
footer {
  padding: 15px 32px 25px;
  color: #95a0b1;
  font-size: 12px;
}
.menu {
  display: none !important;
}
.boot {
  padding: 40px;
}
.gate {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 44% 56%;
  background: white;
}
.gate-brand {
  background: #e5f2fb;
  color: white;
  padding: 70px 11%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.gate-brand h1 {
  font-size: 35px;
  margin: 45px 0 24px;
  max-width: 330px;
}
.gate-brand > p {
  color: #b0bdd9;
  font-size: 17px;
  line-height: 1.8;
}
.gate-brand small {
  font-size: 12px;
  color: #7386ae;
  margin-top: 65px;
}
.gate-points {
  margin-top: 38px;
  font-size: 12px;
  color: #8da2cc;
}
.gate-form {
  padding: 65px 12%;
  align-self: center;
  max-width: 720px;
}
.gate-form h2 {
  font-size: 25px;
  line-height: 1.3;
  margin: 14px 0 25px;
}
.gate-form form > button {
  width: 100%;
  margin-top: 15px;
}
.gate-form p {
  font-size: 12px;
  color: #7a88a0;
}
.gate-form .notice {
  font-size: 12px;
}
.qr {
  display: block;
  width: 210px;
  height: 210px;
}
.recovery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 20px 0;
  font-size: 13px;
}
@media (max-width: 1100px) {
  .sidebar {
    width: 192px;
    padding: 25px 12px;
  }
  .workspace {
    margin-left: 192px;
  }
  .content {
    padding: 23px 22px;
  }
  header {
    padding: 0 22px;
  }
  .filters {
    grid-template-columns: repeat(3, minmax(110px, 1fr));
  }
  .kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .split {
    grid-template-columns: 1fr;
  }
  .form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .breadcrumb {
    font-size: 12px;
  }
  .gate-form {
    padding: 50px 9%;
  }
}
@media (max-width: 800px) {
  button,
  a.button,
  .user button,
  .icon-button {
    min-height: 44px;
  }
  .sidebar {
    visibility: hidden;
    transform: translateX(-100%);
    transition: transform 0.2s;
    width: 224px;
    box-shadow: 10px 0 60px #e5f2fb30;
  }
  .sidebar.open {
    visibility: visible;
    transform: translateX(0);
  }
  .workspace {
    margin-left: 0;
  }
  .menu {
    display: inline-flex !important;
    z-index: 21;
  }
  .sidebar.open {
    z-index: 40;
    padding-top: 64px;
  }
  .nav-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 30;
    border: 0;
    border-radius: 0;
    background: #162f4d70;
    padding: 0;
    width: 100%;
    height: 100%;
  }
  .nav-backdrop:hover {
    filter: none;
  }
  .sidebar-close {
    z-index: 41;
  }
  .tabs button,
  .sidebar nav button {
    min-height: 44px;
  }
  .content {
    padding: 22px 20px;
  }
  header {
    height: 66px;
    padding: 0 20px;
  }
  .gate {
    grid-template-columns: 36% 64%;
  }
  .gate-brand {
    padding: 40px 12%;
  }
  .gate-brand h1 {
    font-size: 25px;
  }
  .gate-brand > p {
    font-size: 14px;
  }
  .gate-points {
    display: none;
  }
  .gate-form {
    padding: 45px 9%;
  }
  .source-banner {
    align-items: flex-start;
    flex-direction: column;
  }
  .form-grid.compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .line-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 500px) {
  .content {
    padding: 22px 14px;
  }
  h1 {
    font-size: 25px;
  }
  .page-heading {
    align-items: flex-start;
    margin-bottom: 22px;
  }
  .eyebrow {
    font-size: 12px;
  }
  .environment {
    font-size: 12px;
    max-width: 105px;
    text-align: right;
  }
  .filters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .filters .field:last-child {
    grid-column: 1/-1;
  }
  .filters input,
  .filters select {
    font-size: 12px;
    padding: 8px;
    min-width: 0;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
  .kpi-grid {
    gap: 10px;
  }
  .kpi {
    padding: 16px 13px;
  }
  .kpi strong {
    font-size: 23px;
  }
  .kpi > small {
    font-size: 12px;
  }
  .panel {
    padding: 17px 14px;
    margin-bottom: 16px;
    border-radius: 12px;
  }
  .panel h2 {
    font-size: 15px;
  }
  .toolbar {
    gap: 8px;
  }
  .toolbar button,
  .toolbar a {
    font-size: 12px;
    padding: 8px 12px;
  }
  header {
    padding: 0 14px;
    gap: 10px;
  }
  .breadcrumb {
    display: none;
  }
  .user > span {
    font-size: 12px;
  }
  .user small {
    font-size: 12px;
  }
  .user {
    gap: 9px;
  }
  .user button {
    font-size: 12px;
  }
  .notice {
    padding: 12px;
    font-size: 12px;
  }
  .gate {
    display: block;
  }
  .gate-brand {
    padding: 24px 28px;
    display: block;
  }
  .gate-brand .logo {
    font-size: 23px;
  }
  .gate-brand h1 {
    font-size: 20px;
    margin: 18px 0 8px;
  }
  .gate-brand > p,
  .gate-brand small {
    display: none;
  }
  .gate-form {
    padding: 35px 26px;
  }
  .gate-form h2 {
    font-size: 23px;
  }
  .line-fields {
    grid-template-columns: 1fr;
  }
  .order-line {
    padding: 10px 8px;
  }
  .line-number {
    font-size: 12px;
  }
  .tabs {
    gap: 0;
  }
  .tabs button {
    padding: 8px;
    font-size: 12px;
  }
  footer {
    padding: 16px;
    font-size: 12px;
  }
  .pagination {
    font-size: 12px;
  }
  .check {
    font-size: 12px;
  }
}

.notifications {
  position: relative;
}
.notifications > summary {
  padding: 7px 10px;
  border: 1px solid #e0e6f1;
  border-radius: 8px;
  list-style: none;
}
.notifications > div {
  position: absolute;
  right: 0;
  top: 42px;
  width: min(310px, 80vw);
  max-height: 420px;
  overflow: auto;
  background: white;
  border: 1px solid #e0e6f1;
  border-radius: 12px;
  padding: 16px;
  z-index: 30;
  box-shadow: 0 12px 40px #14213d20;
}
.notifications p {
  font-size: 12px;
  border-bottom: 1px solid #edf1f8;
  padding-bottom: 10px;
}

.line-product {
  grid-column: 1/-1;
  margin: 0 0 10px;
  color: #5e7497;
  font-size: 12px;
}

.readiness-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.readiness-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px;
  text-align: left;
  white-space: normal;
}

.request-table-wrap {
  max-width: 100%;
  overflow-x: auto;
  margin: 16px 0;
}
.request-table {
  min-width: 1550px;
  width: 100%;
  border-collapse: collapse;
}
.request-table th,
.request-table td {
  padding: 10px;
  border-bottom: 1px solid #e8edf5;
  text-align: left;
  vertical-align: top;
}
.request-table th {
  font-size: 12px;
}
.request-table td:nth-child(2) {
  min-width: 240px;
}
.request-table td small {
  display: block;
  color: #66778e;
  margin-top: 5px;
}
.request-table input:not([type="checkbox"]) {
  min-width: 85px;
  width: 100%;
}
.request-table td:nth-child(8) input {
  width: 65px;
  min-width: 65px;
}
.request-table select {
  min-width: 180px;
  max-width: 230px;
}
.request-table td:last-child {
  min-width: 220px;
}
.advanced {
  margin-top: 24px;
}
.advanced > summary {
  padding: 16px;
  cursor: pointer;
}

.monthly-view {
  width: 100%;
  min-width: 0;
  container-type: inline-size;
}
.monthly-rollup,
.monthly-products-wrap {
  max-width: 100%;
  overflow-x: auto;
}
.monthly-stations,
.monthly-products {
  width: 100%;
  border-collapse: collapse;
}
.monthly-stations {
  min-width: 860px;
}
.monthly-stations th,
.monthly-stations td,
.monthly-products th,
.monthly-products td {
  padding: 12px;
  border-bottom: 1px solid #e6edf6;
  text-align: right;
  vertical-align: top;
}
.monthly-stations thead th,
.monthly-products thead th {
  background: #f2f6fc;
  font-size: 13px;
  white-space: nowrap;
}
.monthly-stations tbody > tr > td:not(:first-child) {
  min-width: 135px;
}
.monthly-stations th:first-child,
.monthly-stations td:first-child {
  text-align: left;
  min-width: 205px;
}
.monthly-stations tbody > tr > td:first-child {
  background: #fff;
}
.monthly-stations td:first-child > .button,
.monthly-stations td:first-child > button {
  display: block;
  margin-top: 8px;
  max-width: 205px;
  white-space: normal;
}
.monthly-stations small,
.monthly-products td:first-child small {
  display: block;
  color: #6c7d94;
  font-size: 12px;
  margin-top: 6px;
}
.monthly-stations tfoot,
.monthly-products tfoot {
  background: #edf3ff;
}
.monthly-detail-container {
  width: calc(100cqw - 28px);
  text-align: left;
  white-space: normal;
  min-width: 0;
}
.monthly-detail-container .panel {
  margin: 0;
}
.monthly-detail-container .panel-title {
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.monthly-detail-container .panel-title h2 {
  margin-bottom: 0;
  overflow-wrap: anywhere;
}
.monthly-expanded > td {
  background: #f7f9fd !important;
}
.monthly-products {
  min-width: 1050px;
}
.monthly-products td:first-child {
  min-width: 230px;
  text-align: left;
}
.monthly-products td {
  min-width: 105px;
}
.monthly-value {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.monthly-value sup {
  color: #9a6a12;
}
.monthly-notes {
  color: #66778e;
  font-size: 12px;
  margin-top: 18px;
}
.monthly-selected > td:first-child {
  border-left: 3px solid #2a83bf;
}

.notification-bell {
  white-space: nowrap;
}
.notification-bell strong {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 10px;
  background: #2a83bf;
  color: white;
  font-size: 12px;
}
.news-center {
  min-width: 0;
  max-width: 100%;
}
.news-center .panel-title,
.news-center .toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.news-list {
  display: grid;
  gap: 16px;
  margin: 18px 0;
}
.news-card {
  min-width: 0;
  padding: 18px;
  border: 1px solid #dfe7f2;
  border-left: 4px solid #c7d2e3;
  border-radius: 10px;
  background: #fff;
  overflow-wrap: anywhere;
}
.news-card.unread {
  border-left-color: #2a83bf;
  background: #f7faff;
}
.news-card.warning {
  border-left-color: #bd850a;
}
.news-card-heading {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}
.news-card-heading > div {
  flex: 1 1 200px;
  min-width: 0;
}
.news-card h3 {
  margin: 8px 0;
}
.news-card small {
  color: #687b94;
}
.news-center details > summary {
  cursor: pointer;
  margin: 12px 0;
}
.news-top-table {
  max-width: 100%;
  overflow-x: auto;
  margin: 16px 0;
}
.news-top-table table {
  min-width: 640px;
}
.news-top-table td {
  padding: 12px;
}
.news-top-table td:nth-child(2) {
  min-width: 200px;
  max-width: 320px;
  white-space: normal;
}
.news-top-table small {
  display: block;
  margin-top: 6px;
}
/* Light blue brand and a focused management overview. */
.logo-compact {
  font-size: 15px;
  letter-spacing: -0.4px;
  border-radius: 8px;
  padding: 6px 9px;
}
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.breadcrumb > span {
  margin: 0;
  color: #8ba5b7;
}
.breadcrumb .logo span {
  color: var(--brand-lime);
  margin-left: 3px;
}
.boot .logo {
  margin-bottom: 20px;
}
.gate-brand {
  color: #1e4b6b;
  background: linear-gradient(140deg, #dfeffc, #edf7fd);
}
.gate-brand > p,
.gate-brand small,
.gate-points {
  color: #55748b;
}
.sidebar {
  background: linear-gradient(180deg, #e8f4fd, #deedf8);
}
.sidebar nav button:hover:not(.selected) {
  background: #ffffff80;
  color: #245e82;
  filter: none;
}
.sidebar-bottom {
  color: #486a82;
}
.panel {
  border-color: #dfeaf2;
  box-shadow: 0 4px 18px #214b6f04;
}
.director-overview,
.store-stock-page {
  min-width: 0;
}
.overview-toolbar {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 12px;
  background: #fff;
  border: 1px solid #e1ebf3;
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 16px;
}
.overview-toolbar .field {
  flex: 1 1 135px;
  min-width: 120px;
  max-width: 260px;
  margin: 0;
}
.overview-toolbar > button {
  margin-bottom: 0;
}
.overview-period {
  min-width: 160px;
  align-self: center;
  margin-right: auto;
}
.filter-caption {
  display: block;
  color: #6f8393;
  font-size: 12px;
  margin-bottom: 6px;
}
.period-presets,
.segmented-control {
  display: flex;
  gap: 4px;
  background: #f0f6fa;
  border-radius: 9px;
  padding: 4px;
}
.period-presets button,
.segmented-control button {
  background: transparent;
  color: #567386;
  border: 0;
  border-radius: 6px;
  font-size: 12px;
  min-height: 31px;
  padding: 5px 12px;
  white-space: nowrap;
}
.period-presets button.active,
.segmented-control button.active {
  background: #fff;
  color: #236d9b;
  box-shadow: 0 2px 6px #23496310;
}
.report-alerts {
  margin: 14px 0 20px;
  padding: 16px;
  border: 1px solid #e7c685;
  border-radius: 14px;
  background: #fff9eb;
  color: #6b460b;
  overflow-wrap: anywhere;
}
.report-alerts .event-preview {
  flex-wrap: wrap;
}
.report-alerts small {
  display: block;
  margin-top: 5px;
  color: #6b460b;
}
.overview-freshness {
  display: flex;
  gap: 8px;
  align-items: center;
  color: #5e7b8c;
  font-size: 12px;
  padding: 0 4px;
  margin: 4px 0 18px;
}
.overview-freshness small {
  display: inline;
  margin-left: 10px;
  color: var(--text-muted);
}
.overview-freshness .link {
  font-size: 12px;
  min-height: 28px;
  margin-left: auto;
}
.freshness-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
  background: #6fae8d;
}
.overview-freshness.attention .freshness-dot {
  background: #d8a348;
}
.overview-updating {
  opacity: 0.65;
  pointer-events: none;
}
.overview-metrics {
  display: grid;
  grid-template-columns: 1.35fr 1fr 1fr 1fr;
  gap: 16px;
  margin-bottom: 22px;
}
.overview-metric {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 9px;
  background: #fff;
  border: 1px solid #e0eaf2;
  border-radius: 14px;
  padding: 21px;
  color: #24455f;
  text-decoration: none;
  min-width: 0;
}
.overview-metric > span {
  font-size: 12px;
  color: #6f8394;
  font-weight: 500;
}
.overview-metric > strong {
  font-size: 30px;
  line-height: 1.2;
  font-weight: 750;
  letter-spacing: -0.8px;
  overflow-wrap: anywhere;
}
.overview-metric > strong small {
  font-size: 17px;
  font-weight: 500;
}
.overview-metric > small {
  font-size: 12px;
  color: #8193a3;
  font-weight: 400;
}
.overview-metric.featured {
  background: linear-gradient(110deg, #e8f4fc, #f8fcff);
  border-color: #cfe4f4;
}
.overview-metric.actionable:hover {
  background: #f6fbff;
  border-color: #b4d9ee;
  filter: none;
}
.trend-positive {
  color: #31846a !important;
}
.trend-negative {
  color: #c06460 !important;
}
.overview-section {
  background: #fff;
  border: 1px solid #e0eaf2;
  border-radius: 15px;
  padding: 22px;
  margin-bottom: 20px;
  min-width: 0;
}
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}
.section-heading h2 {
  font-size: 17px;
  font-weight: 700;
  margin: 0 0 5px;
  color: #25475f;
}
.section-heading p {
  font-size: 12px;
  color: #8295a3;
  margin: 0;
}
.section-heading > button {
  font-size: 13px;
  white-space: nowrap;
}
.count-label {
  background: #eff6fb;
  border-radius: 8px;
  padding: 5px 9px;
  color: #6e8798;
  font-size: 12px;
}
.overview-chart {
  margin: 0;
}
.overview-chart svg {
  width: 100%;
  height: 248px;
  display: block;
}
.chart-label {
  font:
    12px "Segoe UI",
    sans-serif;
  fill: #8295a3;
}
.overview-chart figcaption {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 18px;
  font-size: 12px;
  color: #6d8394;
  margin-top: 6px;
}
.overview-chart figcaption span {
  display: flex;
  align-items: center;
  gap: 7px;
}
.overview-chart figcaption small {
  margin-left: auto;
  color: #95a4b0;
}
.chart-dot {
  display: inline-block;
  width: 16px;
  height: 3px;
  border-radius: 2px;
}
.chart-dot.current {
  background: #348fd0;
}
.chart-dot.previous {
  background: #a5bbcd;
}
.summary-table table {
  min-width: 680px;
}
.summary-table th {
  font-size: 12px;
  font-weight: 600;
  color: #7c91a1;
  background: #f5f9fc;
  text-transform: none;
  padding: 13px 14px;
  border-bottom: 1px solid #e4edf4;
}
.summary-table td {
  font-size: 13px;
  padding: 15px 14px;
  border-bottom: 1px solid #eef3f7;
  vertical-align: middle;
}
.summary-table tr:last-child td {
  border-bottom: 0;
}
.summary-table strong {
  color: #2a4b62;
  font-weight: 600;
}
.summary-table td small {
  font-size: 12px;
  color: #8498a6;
  margin-top: 3px;
}
.section-note {
  font-size: 12px;
  color: #8799a7;
  margin: 14px 0 0;
}
.coverage-good {
  font-size: 12px;
  color: #6c8e7b;
}
.coverage-partial {
  font-size: 12px;
  color: #b48b4e;
}
.product-title strong {
  display: block;
  font-size: 12px;
  max-width: 300px;
  line-height: 1.5;
}
.product-title small {
  display: block;
  font-size: 12px;
  color: #8a9ba8;
  margin-top: 4px;
}
.stock-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 7px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.stock-pill.deficit {
  background: #fff0ec;
  color: #bc7158;
}
.stock-pill.excess {
  background: #fff7e6;
  color: #ae9254;
}
.stock-pill.neutral {
  background: #edf6f2;
  color: #6f9380;
}
.section-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 18px;
}
.section-footer p {
  font-size: 12px;
  color: #8c9da9;
  margin: 0;
}
.section-footer button {
  font-size: 13px;
  white-space: nowrap;
}
.quiet-details {
  margin-top: 14px;
  color: #8094a2;
  font-size: 12px;
}
.quiet-details summary {
  cursor: pointer;
}
.overview-empty {
  padding: 30px 12px;
  text-align: center;
  color: #8398a8;
  background: #f8fbfd;
  border-radius: 10px;
  font-size: 13px;
}
.overview-secondary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: start;
}
.overview-secondary summary {
  font-weight: 600;
  color: #57778d;
  cursor: pointer;
  font-size: 13px;
}
.overview-secondary summary > span {
  color: #93a9b7;
  font-weight: 400;
  margin-left: 8px;
}
.overview-secondary .overview-section {
  padding: 18px 20px;
}
.stock-mobile {
  display: none;
}
.stock-context {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  border: 1px solid #e6eff5;
  border-radius: 9px;
  background: #f7fbfe;
  color: #8094a4;
  font-size: 12px;
  padding: 11px 14px;
  margin-bottom: 16px;
}
.stock-context strong {
  color: #5b7b90;
  font-weight: 500;
}
.stock-mobile-card {
  border: 1px solid #e1ebf2;
  border-radius: 12px;
  padding: 16px;
}
.stock-mobile-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
  color: #7f95a5;
  margin-bottom: 12px;
}
.stock-mobile-values {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 16px 0;
}
.stock-mobile-values > div {
  padding: 12px;
  background: #f4f9fc;
  border-radius: 9px;
  min-width: 0;
}
.stock-mobile-values small {
  display: block;
  color: #8197a7;
  font-size: 12px;
}
.stock-mobile-values strong {
  display: block;
  font-size: 20px;
  color: #2e536e;
  margin-top: 5px;
  overflow-wrap: anywhere;
}
.stock-mobile-values strong small {
  display: inline;
  font-weight: 400;
}
.stock-message {
  border: 1px solid #e1ebf2;
  border-radius: 10px;
  padding: 15px;
  margin-top: 10px;
}
.stock-message summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  font-size: 13px;
  color: #3b627c;
}
.stock-message p {
  font-size: 12px;
  line-height: 1.8;
  color: #628095;
}
.stock-dialog {
  border: 1px solid #d9e8f3;
  border-radius: 18px;
  padding: 26px;
  width: min(540px, calc(100vw - 32px));
  box-shadow: 0 24px 90px #244c6c24;
  color: #33556c;
  max-height: calc(100vh - 36px);
  overflow-y: auto;
}
.supplier-export-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 12px;
}
.supplier-export-card {
  border: 1px solid #d9e8f3;
  border-radius: 12px;
  padding: 16px;
  overflow-wrap: anywhere;
}
.event-dialog {
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
  overflow-wrap: anywhere;
}
.event-dialog-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}
.stock-dialog::backdrop {
  background: #284b6670;
  backdrop-filter: blur(3px);
}
.stock-dialog h3 {
  font-size: 17px;
  margin: 8px 0;
}
.stock-dialog .section-heading {
  margin-bottom: 10px;
}
.dialog-close {
  font-size: 21px;
  padding: 0 10px;
  min-height: 32px;
}
.dialog-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 20px;
}
.stock-inbox .section-heading {
  margin-bottom: 8px;
}
@media (max-width: 1150px) {
  .overview-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .overview-toolbar .field {
    max-width: none;
  }
  .overview-period {
    min-width: 145px;
  }
}
@media (max-width: 760px) {
  .overview-secondary {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .overview-section {
    padding: 16px;
    border-radius: 12px;
  }
  .section-heading {
    align-items: flex-start;
    gap: 10px;
    flex-wrap: wrap;
  }
  .overview-toolbar {
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding: 13px;
    gap: 10px;
  }
  .overview-toolbar .field {
    min-width: 0;
  }
  .overview-toolbar .overview-period {
    grid-column: 1/-1;
    width: 100%;
  }
  .overview-toolbar .overview-period .period-presets {
    width: fit-content;
  }
  .overview-toolbar > button {
    width: 100%;
  }
  .overview-freshness {
    align-items: flex-start;
  }
  .overview-freshness small {
    display: block;
    margin: 4px 0 0;
  }
  .freshness-dot {
    margin-top: 6px;
  }
  .section-footer {
    align-items: flex-start;
    flex-direction: column;
  }
  .section-footer .pager {
    flex-wrap: wrap;
  }
  .overview-chart svg {
    height: 200px;
  }
  .overview-chart figcaption small {
    margin-left: 0;
    width: 100%;
  }
  .overview-metrics {
    gap: 10px;
  }
  .overview-metric {
    padding: 16px;
  }
  .overview-metric > strong {
    font-size: 26px;
  }
  .stock-context {
    gap: 8px;
    flex-direction: column;
  }
}
@media (max-width: 540px) {
  .stock-desktop {
    display: none;
  }
  .stock-mobile {
    display: grid;
    gap: 12px;
  }
  .overview-metric.featured {
    grid-column: 1/-1;
  }
  .overview-metrics > .overview-metric:nth-child(4) {
    grid-column: 1/-1;
  }
  .overview-metric > strong {
    font-size: 25px;
  }
  .overview-chart svg {
    height: 175px;
  }
  .chart-label {
    font-size: 15px;
  }
  .stock-dialog {
    padding: 18px;
  }
  .dialog-actions {
    flex-direction: column-reverse;
  }
  .dialog-actions button {
    width: 100%;
  }
  .overview-freshness .link {
    white-space: nowrap;
  }
}
/* Legible small labels and semantic status colours. */
:root {
  --brand-blue: #2379b4;
}
button,
a.button {
  background: #2379b4;
}
.muted {
  color: #60798c;
}
.director-overview .filter-caption,
.overview-metric > span {
  color: #607688;
}
.overview-metric > small,
.overview-freshness small,
.section-heading p,
.section-note,
.summary-table td small,
.product-title small,
.stock-mobile-values small,
.section-footer p,
.quiet-details,
.stock-context {
  color: #60798c;
}
.summary-table th,
.overview-chart figcaption,
.stock-mobile-top {
  color: #526e82;
}
.chart-label {
  fill: #60798c;
}
.coverage-good {
  color: #3d7659;
}
.coverage-partial {
  color: #8b6b32;
}
.stock-pill.deficit {
  color: #9d4f36;
}
.stock-pill.excess {
  color: #8d6d2d;
}
.stock-pill.neutral {
  color: #49775c;
}
.count-label {
  color: #4f6d83;
}
.stock-pill.unknown {
  color: #6b6a56;
  background: #f4f5ee;
}
.batch-review-card {
  border: 1px solid #cde1ef;
  border-radius: 12px;
  padding: 18px;
  margin: 16px 0;
  background: #f4faff;
}
.batch-review-counts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 10px;
  margin: 14px 0;
}
.batch-review-counts > span {
  padding: 12px;
  background: white;
  border: 1px solid #e0ebf3;
  border-radius: 9px;
  font-size: 12px;
}
.batch-review-counts strong {
  display: block;
  font-size: 23px;
  color: #285d7e;
}
.estimate-label {
  color: #805b1f;
}
.request-topbar,
.request-lead,
.vendor-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.request-topbar {
  margin-bottom: 16px;
}
.request-lead {
  margin: 8px 0 20px;
  color: #66788e;
}
.request-lead strong {
  color: #213e5b;
  font-size: 17px;
}
.request-lead .toolbar {
  margin: 0;
}
.request-document .panel-title h2 {
  margin: 0;
}
.request-document .panel-title {
  margin-bottom: 12px;
}
.request-tabs {
  display: flex;
  gap: 6px;
  border-bottom: 1px solid #dfebf5;
  margin: 18px 0;
}
.request-tabs button {
  background: transparent;
  border: 0;
  border-bottom: 3px solid transparent;
  color: #667a92;
  padding: 13px 18px;
  border-radius: 0;
}
.request-tabs button.active {
  color: #1677b7;
  border-color: #2899d4;
  background: #f1f9ff;
}
.request-product-filters {
  display: grid;
  grid-template-columns: minmax(200px, 1fr) minmax(180px, 260px);
  gap: 16px;
  margin: 18px 0;
}
.simple-request-wrap {
  width: 100%;
}
.simple-request-table {
  width: 100%;
  table-layout: fixed;
  white-space: normal;
  font-size: 13px;
}
.simple-request-table th {
  padding: 12px 10px;
}
.simple-request-table th:first-child {
  width: 34%;
}
.simple-request-table td {
  padding: 10px;
  overflow: visible;
  max-width: none;
  vertical-align: top;
  overflow-wrap: anywhere;
}
.simple-request-table td small {
  display: block;
  color: var(--text-muted);
  margin-top: 5px;
  font-size: 12px;
}
.simple-request-table .request-include {
  width: 38px;
}
.simple-request-table:has(.request-include) th:first-child {
  width: 38px;
}
.simple-request-table:has(.request-include) th:nth-child(2) {
  width: 30%;
}
.simple-request-table input:not([type="checkbox"]),
.simple-request-table select {
  min-width: 0;
  width: 100%;
}
.simple-request-table select {
  padding: 10px 8px;
}
.request-quantity {
  color: #1f638c;
}
.quantity-editor {
  display: grid;
  gap: 4px;
}
.quantity-editor span {
  color: #7b8da1;
  font-size: 12px;
}
.request-row-details {
  margin-top: 7px;
  font-size: 12px;
}
.request-row-details summary,
.request-calculation-details summary,
.request-more summary {
  color: #6f859c;
  cursor: pointer;
}
.request-row-details[open] {
  padding: 10px;
  background: #f3f8fc;
  border-radius: 7px;
}
.request-row-details p {
  margin: 7px 0;
  font-size: 12px;
}
.request-supplier {
  font-size: 12px;
  color: #566d85;
}
.request-more {
  padding: 10px 0;
}
.request-more[open] {
  padding: 12px;
  border: 1px solid #dfebf5;
  border-radius: 8px;
  background: #f8fbfe;
}
.request-more > .button,
.request-more > .field {
  margin: 8px 4px 0 0;
}
.request-pager {
  justify-content: flex-end;
  margin: 18px 0;
}
.request-pager > span {
  margin-right: auto;
  color: var(--text-muted);
  font-size: 12px;
}
.request-savebar,
.request-approval {
  padding: 16px;
  background: #f2f9fe;
  border: 1px solid #dcecf7;
  border-radius: 10px;
  margin-top: 16px;
}
.request-savebar {
  position: sticky;
  bottom: 12px;
  z-index: 2;
  box-shadow: 0 3px 15px #355a7612;
}
.request-savebar > span {
  color: #658097;
  font-size: 12px;
}
.request-approval .check {
  margin: 0 0 12px;
}
.request-calculation-details {
  border-top: 1px solid #e5eef5;
  padding-top: 16px;
  margin-top: 24px;
}
.request-calculation-details p {
  color: var(--text-muted);
  font-size: 12px;
}
.request-vendor-list {
  display: grid;
  gap: 10px;
  margin: 18px 0;
}
.compact-vendor {
  padding: 14px 16px;
  min-height: 0;
}
.vendor-summary > div {
  flex: 1;
  min-width: 0;
}
.vendor-summary strong {
  overflow-wrap: anywhere;
  font-size: 13px;
}
.vendor-summary small {
  display: block;
  color: var(--text-muted);
  margin-top: 5px;
}
.compact-vendor > details {
  margin-top: 9px;
  color: #6a8096;
  font-size: 12px;
}
.vendor-summary > .vendor-row-actions {
  flex: 0 1 auto;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.supplier-sent-state {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  margin-top: 12px;
  font-size: 12px;
  color: #577185;
}
.supplier-sent-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #206442;
  background: #e9f7ee;
  border: 1px solid #c4e6d1;
  padding: 6px 9px;
  border-radius: 8px;
  font-weight: 600;
}
.supplier-not-sent {
  font-size: 12px;
  color: var(--text-muted);
  margin: 10px 0 0;
}
.supplier-dispatch-form {
  margin-top: 12px;
  padding: 12px 14px;
  border: 1px solid #c8e1f7;
  border-radius: 10px;
  background: #f3f9ff;
  font-size: 13px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}
.supplier-dispatch-form label {
  max-width: 340px;
}
.supplier-dispatch-form .toolbar {
  margin: 12px 0 0;
}
.supplier-dispatch-choice {
  align-items: center;
  min-height: 32px;
}
.supplier-batch-actions {
  margin: 16px 0;
}
.supplier-batch-actions > small {
  display: block;
  color: #526a80;
  line-height: 1.6;
}
.product-pack-hint {
  display: block;
  color: #526a80;
  margin-top: 6px;
  line-height: 1.5;
}
.supplier-batch-actions .toolbar {
  flex-wrap: wrap;
}
.supplier-batch-actions .supplier-dispatch-form ul {
  max-height: 180px;
  overflow: auto;
  padding-left: 22px;
}
.supplier-sent-state button {
  padding: 7px 10px;
  font-size: 12px;
}
@media (max-width: 680px) {
  .vendor-summary > .vendor-row-actions {
    width: 100%;
  }
  .vendor-row-actions > .button,
  .vendor-row-actions > button {
    flex: 1;
    min-width: 0;
    white-space: normal;
    justify-content: center;
    text-align: center;
  }
}
.compact-vendor ul {
  padding-left: 18px;
  line-height: 1.8;
}
.request-print-only {
  display: none;
}
.calculation-settings,
.secondary-result-views {
  margin: 14px 0;
}
.calculation-settings > summary,
.secondary-result-views > summary {
  cursor: pointer;
  padding: 8px 0;
  color: #6f859c;
  font-size: 12px;
}
.calculation-settings[open] {
  padding: 12px;
  border: 1px solid #e1ecf5;
  border-radius: 9px;
}
@media (max-width: 800px) {
  .request-product-filters {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .request-tabs {
    gap: 0;
  }
  .request-tabs button {
    padding: 12px 10px;
    font-size: 12px;
    flex: 1;
  }
  .request-document .panel {
    padding: 18px 14px;
  }
  .simple-request-table,
  .simple-request-table > tbody {
    display: block;
  }
  .simple-request-table > thead {
    display: none;
  }
  .simple-request-table > tbody > tr {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    padding: 16px 0;
    border-bottom: 1px solid #e4edf5;
  }
  .simple-request-table > tbody > tr > td {
    display: block;
    padding: 0;
    border: 0;
  }
  .simple-request-table .request-product,
  .simple-request-table .request-supplier {
    grid-column: 1 / -1;
  }
  .simple-request-table .request-product {
    grid-row: 1;
  }
  .simple-request-table .request-include {
    grid-column: 1 / -1;
    width: auto;
  }
  .simple-request-table .request-include::after {
    content: " Включить в заявку";
    color: var(--text-muted);
    font-size: 12px;
  }
  .simple-request-table td[data-label]::before {
    content: attr(data-label);
    display: block;
    color: var(--text-muted);
    font-size: 12px;
    margin-bottom: 5px;
  }
  .simple-request-table .request-quantity {
    grid-column: 2;
    grid-row: 2 / 4;
    padding: 10px;
    background: #f2f9fe;
    border-radius: 7px;
  }
  .simple-request-table .request-supplier {
    font-size: 12px;
  }
  .request-quantity strong {
    font-size: 18px;
  }
  .vendor-summary {
    gap: 10px;
  }
  .vendor-summary > .button {
    font-size: 12px;
    padding: 9px 12px;
  }
}
@media print {
  .workspace {
    margin-left: 0 !important;
  }
  .shell,
  .body,
  .content {
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }
  :root,
  body {
    background: white;
  }
  .no-print,
  nav,
  aside,
  header,
  footer,
  .skip-link,
  .toast {
    display: none !important;
  }
  .request-document {
    width: 100%;
  }
  .request-document .panel {
    border: 0;
    box-shadow: none;
    padding: 0;
  }
  .request-document .panel-title {
    break-after: avoid;
  }
  .request-print-only {
    display: block;
  }
  .request-print-only table {
    table-layout: fixed;
    white-space: normal;
    font-size: 10px;
  }
  .request-print-only thead {
    display: table-header-group;
    position: static;
  }
  .request-print-only tr {
    break-inside: avoid;
  }
  .request-print-only th:first-child {
    width: 50%;
  }
  .request-print-only td {
    overflow: visible;
    overflow-wrap: anywhere;
    padding: 7px;
    max-width: none;
  }
}
.supplier-choice-list .table-wrap {
  max-height: none;
}
.supplier-choice-list td {
  vertical-align: top;
  overflow-wrap: anywhere;
}
.supplier-choice-list td:nth-child(2) .button {
  margin-top: 8px;
  text-align: left;
}
@media (max-width: 1100px) {
  .supplier-choice-list .table-wrap {
    overflow: visible;
    border: 0;
  }
  .supplier-choice-list table,
  .supplier-choice-list tbody {
    display: block;
    min-width: 0;
    width: 100%;
  }
  .supplier-choice-list thead {
    display: none;
  }
  .supplier-choice-list tr {
    display: block;
    border: 1px solid #dce8f3;
    border-radius: 10px;
    margin: 12px 0;
    padding: 12px;
  }
  .supplier-choice-list td {
    display: block;
    width: auto;
    padding: 8px 0;
    border: 0;
    white-space: normal;
  }
  .supplier-choice-list .button {
    max-width: 100%;
    white-space: normal;
  }
}
@media (max-width: 500px) {
  header .breadcrumb {
    font-size: 0;
    gap: 0;
    flex-shrink: 0;
  }
  header .breadcrumb > span {
    display: none;
  }
  header .user {
    gap: 8px;
    min-width: 0;
  }
}
.access-people {
  display: grid;
  gap: 12px;
}
.access-person {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--line, #d6e4f5);
  border-radius: 12px;
  background: #fff;
}
.access-person > div:first-child {
  display: grid;
  gap: 5px;
  min-width: 0;
  flex: 1 1 260px;
  overflow-wrap: anywhere;
}
.access-person .toolbar {
  margin: 0;
  flex-wrap: wrap;
}
@media (max-width: 680px) {
  .access-person .toolbar {
    width: 100%;
  }
  .access-person .toolbar > button {
    flex: 1 1 140px;
  }
}
.store-map {
  width: 100%;
  height: 360px;
  border: 1px solid #dbe8f4;
  border-radius: 12px;
  margin-top: 12px;
}
.calculation-explanation[open] {
  width: min(32rem, calc(100vw - 88px));
  white-space: normal;
  overflow-wrap: anywhere;
}
.forecast-explanation {
  min-width: 0;
}
.forecast-explanation .table-wrap {
  max-width: 100%;
}
.nav-more {
  margin-top: 12px;
  width: 100%;
}
.nav-more summary {
  padding: 12px;
  color: #355770;
  font-size: 13px;
  min-height: 44px;
  cursor: pointer;
  border-radius: 8px;
}
.nav-more summary:hover {
  background: #d8ecfa;
}
.nav-more summary:focus-visible {
  outline: 2px solid var(--brand-blue);
  outline-offset: -2px;
}
.nav-more > button {
  width: 100%;
  margin-top: 4px;
}
.sidebar nav button,
.tabs button {
  min-height: 44px;
}
.forecast-navigation {
  display: flex;
  align-items: end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 20px;
}
.forecast-navigation .tabs {
  margin: 0;
}
.forecast-navigation .field {
  flex: 0 1 260px;
  margin: 0;
}
.forecast-navigation select {
  min-height: 44px;
}
.forecast-freshness,
.calculation-context {
  color: #53677f;
  font-size: 13px;
  line-height: 1.6;
}
.forecast-method {
  margin: 8px 0 16px;
}
.forecast-method summary {
  min-height: 44px;
  padding: 10px 0;
  cursor: pointer;
  color: #235f88;
}
.forecast-list-row {
  display: flex;
  gap: 16px;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid #e7edf5;
}
.forecast-list-row > div {
  min-width: 0;
  flex: 1;
}
.forecast-list-row strong {
  display: block;
  overflow-wrap: anywhere;
}
.forecast-list-row small {
  display: block;
  color: #53677f;
  margin-top: 6px;
}
.forecast-list-row button {
  flex-shrink: 0;
}
.forecast-detail {
  margin-top: 24px;
  padding-top: 20px;
}
.forecast-detail h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.4;
}
.batch-review-card > summary {
  min-height: 44px;
  cursor: pointer;
  padding: 8px 0;
  color: #235f88;
  font-weight: 600;
}

/* 048: quiet navigation, readable work surfaces, one next action. */
::selection {
  background: #d5eafb;
  color: #142b43;
}
input,
textarea {
  caret-color: var(--brand-blue);
}
* {
  scrollbar-width: thin;
  scrollbar-color: #a9bac9 #f2f6f9;
}
button,
a.button {
  transition:
    background-color 140ms ease-out,
    border-color 140ms ease-out;
}
a {
  text-underline-offset: 3px;
}
summary {
  cursor: pointer;
}
summary:focus-visible,
textarea:focus-visible {
  outline: 3px solid #9ac8e9;
  outline-offset: 3px;
}
button svg,
.button svg {
  flex-shrink: 0;
}
table,
.overview-metric,
.comparison-store-values,
.calculation-results {
  font-variant-numeric: tabular-nums;
}
.header-brand {
  display: none;
}
.workspace-short {
  display: none;
}
.sidebar-brand {
  margin-bottom: 24px;
}
.sidebar-brand .brand-caption {
  margin-bottom: 0;
}
.sidebar nav button {
  gap: 8px;
  padding: 8px 12px;
}
.breadcrumb {
  color: var(--text-secondary);
}
.panel-title {
  gap: 16px;
}
.field,
.field > span,
.check {
  color: var(--text-secondary);
}
.field small,
.columns,
.pagination,
.user small {
  color: var(--text-muted);
}
.request-registry .registry-primary-filters {
  grid-template-columns: repeat(3, minmax(140px, 1fr));
}
.registry-advanced {
  border-top: 1px solid var(--line);
  padding-top: 4px;
  margin-top: 16px;
}
.registry-advanced summary,
.legacy-receipt-details > summary {
  padding: 12px 0;
  color: var(--text-secondary);
}
.registry-advanced .filters {
  margin-top: 12px;
}
.registry-toolbar {
  justify-content: space-between;
}
.registry-display {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
}
.sales-toolbar {
  justify-content: space-between;
}
.download-menu {
  position: relative;
}
.download-menu > summary {
  list-style: none;
  min-height: 40px;
  padding: 8px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text-secondary);
  background: #fff;
}
.download-menu > summary::-webkit-details-marker {
  display: none;
}
.download-options {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding-top: 8px;
}
.calculation-context-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 16px 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  margin-bottom: 20px;
}
.calculation-context-bar > div {
  display: grid;
  gap: 4px;
}
.calculation-context-bar span {
  color: var(--text-muted);
  font-size: 13px;
}
.calculation-results {
  scroll-margin-top: 24px;
  outline: none;
}
.calculation-results .panel-title {
  align-items: flex-start;
}
.calculation-view-button {
  background: #fff;
  color: var(--text-secondary);
  border-color: var(--line);
}
.calculation-view-button[aria-pressed="true"] {
  background: #eaf4fb;
  color: #175d8b;
  border-color: #9fc6df;
}
.calculation-result-table .table-wrap {
  max-height: none;
}
.calculation-result-table td {
  vertical-align: top;
  white-space: normal;
}
.calculation-result-table td[data-column="name"] {
  min-width: 220px;
}
.calculation-result-table td[data-column="quantity"] {
  min-width: 180px;
}
.calculation-result-table td[data-column="supplier_id"] {
  min-width: 240px;
  max-width: 360px;
}
.calculation-result-table td small {
  margin-top: 4px;
  color: var(--text-muted);
  font-size: 12px;
}
.calculation-review-help {
  margin-top: 12px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-secondary);
  overflow-wrap: anywhere;
}
.calculation-review-help > strong {
  color: #805517;
}
.calculation-review-help ul {
  list-style: none;
  padding: 0;
  margin: 8px 0 0;
}
.calculation-review-help li + li {
  margin-top: 12px;
}
.calculation-review-help p {
  margin: 0 0 4px;
}
.calculation-explanation-trigger {
  text-align: left;
  white-space: normal;
}
.calculation-supplier-source {
  margin-top: 8px;
  color: var(--text-muted);
  font-size: 12px;
}
.calculation-supplier-source summary {
  padding: 4px 0;
}
.calculation-explanation-panel {
  border: 1px solid #b7d4e8;
  border-radius: 12px;
  padding: 20px;
  margin: 20px 0;
  background: #f8fbfe;
  scroll-margin-top: 24px;
  overflow-wrap: anywhere;
}
.calculation-explanation-panel:focus {
  outline: 2px solid #9ac8e9;
  outline-offset: 3px;
}
.calculation-explanation-heading {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 16px;
}
.calculation-explanation-heading h3 {
  margin: 0;
  font-size: 18px;
}
.calculation-explanation-content,
.calculation-explanation-content .forecast-explanation {
  width: 100%;
  max-width: none;
  min-width: 0;
}
.calculation-explanation-content p {
  max-width: 85ch;
}
.calculation-savebar {
  position: sticky;
  bottom: 12px;
  z-index: 3;
  margin-top: 24px;
  padding: 16px 20px;
  background: #fff;
  border: 1px solid #b7d4e8;
  border-radius: 12px;
  box-shadow: 0 4px 20px #203e5714;
}
.calculation-savebar .toolbar {
  margin: 12px 0 0;
}
.calculation-savebar .check {
  margin: 12px 0;
}
.calculation-savebar .notice {
  margin: 12px 0;
}
.calculation-save-options {
  color: var(--text-secondary);
  margin-top: 12px;
}
.calculation-save-options > summary {
  padding: 4px 0;
}
.event-list-toolbar {
  display: flex;
  gap: 12px;
  align-items: end;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.event-list-toolbar .field {
  flex: 1 1 200px;
  max-width: 320px;
  margin: 0;
}
.event-view-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}
.event-view-tabs button {
  background: #fff;
  color: var(--text-secondary);
  border-color: var(--line);
}
.event-view-tabs button[aria-pressed="true"] {
  background: #eaf4fb;
  color: #175d8b;
  border-color: #9fc6df;
}
.event-state-help {
  color: var(--text-muted);
  font-size: 13px;
  margin: 8px 0 16px;
}
.event-advanced-filters {
  border-top: 1px solid var(--line);
  padding-top: 8px;
  margin-bottom: 16px;
}
.event-advanced-filters > summary {
  padding: 8px 0;
  color: var(--text-secondary);
}
.business-event-feed {
  list-style: none;
  padding: 0;
  margin: 0;
}
.business-event-item {
  border-bottom: 1px solid var(--line);
}
.business-event-item:last-child {
  border-bottom: 0;
}
.event-open {
  display: grid;
  gap: 8px;
  width: 100%;
  padding: 20px 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  color: var(--text-primary);
  text-align: left;
  font-weight: 400;
  justify-content: stretch;
}
.event-open:hover {
  background: #f6f9fc;
  filter: none;
}
.event-open > strong {
  font-size: 15px;
  font-weight: 600;
  overflow-wrap: anywhere;
}
.event-feed-context,
.event-feed-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  font-size: 12px;
  color: var(--text-muted);
}
.event-open-label {
  font-size: 13px;
  color: #175d8b;
}
.event-processing.requires_action {
  color: #805517;
}
.event-processing.resolved {
  color: #2d684b;
}
.event-unread {
  color: #175d8b;
  font-weight: 600;
}
.comparison-mobile {
  display: none;
}
.overview-event-list {
  display: grid;
}
.overview-events .event-preview {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.overview-events .event-preview:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}
.overview-events .event-preview > div {
  min-width: 0;
}
.overview-events .event-preview strong {
  display: block;
  overflow-wrap: anywhere;
}
.overview-event-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  color: var(--text-muted);
  font-size: 12px;
  margin-top: 4px;
}
.event-importance {
  color: var(--text-secondary);
}
.event-importance.critical {
  color: #a23232;
}
.event-importance.warning {
  color: #805517;
}
.invoice-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  padding: 0;
  margin: 0 0 20px;
  list-style: none;
  color: var(--text-muted);
  font-size: 13px;
}
.invoice-step.current {
  color: #175d8b;
  font-weight: 600;
}
.invoice-step.complete {
  color: #2d684b;
}
.invoice-dropzone {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: 28px 20px;
  border: 1px dashed #91b4ce;
  border-radius: 12px;
  background: #f8fbfd;
  text-align: center;
  color: var(--text-secondary);
}
.invoice-dropzone.dragging,
.invoice-dropzone.has-file {
  border-color: #3988bb;
  background: #eaf4fb;
}
.invoice-dropzone input {
  max-width: 440px;
}
.invoice-store,
.invoice-review-fields {
  border: 0;
  padding: 0;
  margin: 0;
  min-width: 0;
}
.invoice-file-input {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 0;
  padding: 0;
  border: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.invoice-step {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.invoice-step > span {
  font-variant-numeric: tabular-nums;
}
.invoice-progress:empty {
  display: none;
}
.invoice-file-meta {
  font-size: 13px;
  color: var(--text-secondary);
  overflow-wrap: anywhere;
}
.invoice-upload-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 16px;
}
.invoice-progress {
  padding: 16px;
  background: #edf6fc;
  border: 1px solid #c3dfef;
  border-radius: 8px;
  margin-top: 16px;
}
.invoice-empty {
  padding: 28px 20px;
  text-align: center;
  color: var(--text-secondary);
}
.invoice-empty h3 {
  color: var(--text-primary);
  margin-bottom: 8px;
}
.receipt-request-selection {
  margin: 24px 0;
  padding: 20px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.receipt-request-selection h3 {
  margin-bottom: 8px;
}
.receipt-request-selection > p {
  color: var(--text-secondary);
  max-width: 75ch;
}
.receipt-manual-request {
  margin-top: 16px;
  color: var(--text-secondary);
}
.receipt-manual-request > summary {
  padding: 8px 0;
}
.receipt-manual-search {
  display: flex;
  gap: 12px;
  align-items: end;
  flex-wrap: wrap;
  margin-top: 12px;
}
.receipt-manual-search .field {
  flex: 1 1 200px;
  max-width: 320px;
}
.receipt-request-found {
  color: #2d684b;
}
.receipt-actions {
  padding-top: 16px;
  margin-top: 20px;
  border-top: 1px solid var(--line);
}
.receipt-actions .check {
  margin-bottom: 16px;
}
.legacy-receipt-details {
  margin-top: 24px;
  border-top: 1px solid var(--line);
}
.admin-intro {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin-bottom: 16px;
  color: var(--text-muted);
  font-size: 12px;
}
.admin-context > summary {
  min-height: 32px;
  padding: 4px 0;
  color: var(--text-secondary);
}
.admin-context p {
  max-width: 75ch;
  margin: 8px 0;
}
.admin-local-mode {
  font-size: 12px;
  color: var(--text-muted);
}
.admin-groups,
.admin-subtabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.admin-groups {
  border-bottom: 1px solid var(--line);
  margin-bottom: 16px;
}
.admin-groups button {
  border-radius: 8px 8px 0 0;
  border-color: transparent !important;
  background: transparent !important;
  color: var(--text-secondary) !important;
  padding: 12px 16px;
  min-height: 44px;
}
.admin-groups button.selected {
  color: #175d8b !important;
  background: #eaf4fb !important;
  border-bottom-color: var(--brand-blue) !important;
}
.admin-subtabs {
  margin: 0 0 20px;
}
.admin-subtabs button {
  min-height: 36px;
  font-size: 13px;
  padding: 6px 12px;
}
.admin-subtabs button.selected {
  color: #175d8b;
  background: #eaf4fb;
  border-color: #9fc6df;
}
.admin-release {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  padding-top: 16px;
  margin-top: 16px;
  border-top: 1px solid var(--line);
  color: var(--text-muted);
  font-size: 12px;
  overflow-wrap: anywhere;
}
.admin-component-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 24px;
}
.admin-component {
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
  min-width: 0;
}
.admin-component h3 {
  margin: 0;
}
.admin-component > header {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  padding: 0;
  height: auto;
  border: 0;
  background: transparent;
}
.admin-component p {
  color: var(--text-secondary);
  margin: 12px 0;
  overflow-wrap: anywhere;
}
.admin-component-state {
  font-size: 12px;
  flex-shrink: 0;
}
.admin-component-state.working {
  color: #2d684b;
}
.admin-component-state.problem {
  color: #805517;
}
.admin-component-state.unavailable {
  color: #a23232;
}
.admin-component-state.not_configured,
.admin-component-state.no_data {
  color: var(--text-muted);
}
.admin-component-meta {
  color: var(--text-muted);
  font-size: 12px;
}
.admin-help {
  margin-top: 24px;
  color: var(--text-secondary);
}
.admin-help summary {
  min-height: 40px;
  padding: 8px 0;
}
.admin-help li {
  margin-bottom: 8px;
}
@media (max-width: 800px) {
  .header-brand {
    display: block;
  }
  .header-brand .logo {
    font-size: 18px;
    border-radius: 8px;
    padding: 8px 10px;
  }
  .sidebar-brand {
    display: none;
  }
  .calculation-savebar {
    bottom: 8px;
    padding: 12px;
  }
  .calculation-savebar > .toolbar {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }
  .calculation-savebar > .toolbar > button {
    min-width: 0;
    padding: 10px 4px;
    gap: 4px;
    font-size: 12px;
  }
  .calculation-context-bar {
    padding: 16px;
    align-items: stretch;
  }
  .calculation-context-bar > div {
    flex: 1 1 100%;
  }
  .calculation-context-bar > button {
    width: 100%;
  }
  .calculation-result-table .table-wrap {
    overflow: visible;
    max-height: none;
  }
  .calculation-result-table table,
  .calculation-result-table tbody {
    display: block;
  }
  .calculation-result-table thead {
    display: none;
  }
  .calculation-result-table tbody > tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
    padding: 20px 0;
    border-bottom: 1px solid var(--line);
  }
  .calculation-result-table tbody > tr:hover {
    background: transparent;
  }
  .calculation-result-table td {
    display: block;
    padding: 0;
    border: 0;
    width: 100%;
    max-width: none !important;
    min-width: 0 !important;
    overflow: visible;
  }
  .calculation-result-table td[data-column="name"] {
    grid-row: 1;
  }
  .calculation-result-table td[data-column="quantity"]::before,
  .calculation-result-table td[data-column="supplier_id"]::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 4px;
    color: var(--text-muted);
    font-size: 13px;
  }
  .calculation-result-table td[data-column="quantity"] input {
    max-width: 220px;
  }
  .calculation-result-table td small {
    font-size: 13px;
    line-height: 1.6;
  }
  .calculation-explanation-panel {
    padding: 16px;
  }
  .calculation-explanation-heading {
    flex-wrap: wrap;
  }
  .calculation-explanation-heading h3 {
    font-size: 16px;
  }
  .calculation-savebar {
    max-height: 45vh;
    overflow-y: auto;
  }
  .calculation-savebar .calculation-selection-summary {
    margin-bottom: 8px;
  }
  .request-registry .registry-primary-filters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .request-registry .table-wrap {
    max-height: none;
  }
}
@media (max-width: 640px) {
  header > .user {
    min-width: 0;
    gap: 8px;
  }
  header > .user > span {
    min-width: 0;
    font-size: 12px;
  }
  header .workspace-full,
  header > .user > span > small {
    display: none;
  }
  header .workspace-short {
    display: inline;
  }
  .comparison-desktop {
    display: none;
  }
  .comparison-mobile {
    display: grid;
  }
  .comparison-store {
    padding: 20px 0;
    border-bottom: 1px solid var(--line);
  }
  .comparison-store:first-child {
    padding-top: 0;
  }
  .comparison-store:last-child {
    padding-bottom: 0;
    border-bottom: 0;
  }
  .comparison-store-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
  }
  .comparison-store-head h3 {
    margin: 0;
    font-size: 16px;
  }
  .comparison-store-values {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .comparison-store-values > span {
    display: grid;
    gap: 4px;
  }
  .comparison-store-values strong {
    font-size: 20px;
    font-weight: 600;
    overflow-wrap: anywhere;
  }
  .comparison-store-values small {
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 400;
  }
  .comparison-store-context {
    margin: 12px 0 8px;
    color: var(--text-secondary);
    font-size: 13px;
  }
  .comparison-store-detail {
    font-size: 13px;
    color: var(--text-secondary);
  }
  .comparison-store-detail summary {
    padding: 4px 0;
  }
  .comparison-store-detail dl > div {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 8px;
  }
  .comparison-store-detail dd {
    margin: 0;
    text-align: right;
  }
  .overview-events .event-preview {
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 8px;
  }
  .overview-events .event-preview > div {
    flex: 1 1 100%;
  }
  .admin-component-grid {
    grid-template-columns: 1fr;
  }
  .admin-groups {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
  }
  .admin-groups button {
    border-radius: 8px;
    text-align: left;
    justify-content: flex-start;
  }
  .admin-component > header {
    align-items: flex-start;
    flex-wrap: wrap;
  }
  .invoice-dropzone {
    padding: 20px 12px;
  }
  .invoice-upload-actions > button {
    width: 100%;
  }
  .invoice-steps {
    gap: 8px 12px;
  }
}
@media (prefers-reduced-motion: reduce) {
  button,
  a.button {
    transition: none;
  }
}
@media (max-width: 600px) {
  .forecast-navigation {
    display: block;
  }
  .forecast-navigation .field {
    margin-top: 16px;
  }
  .forecast-list-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }
  .forecast-list-row button {
    width: 100%;
  }
  .forecast-detail .panel-title {
    flex-direction: column;
    align-items: stretch;
  }
}

/* One server stock position in calculations, saved requests and stock views. */
.stock-position {
  min-width: 0;
  white-space: normal;
  overflow-wrap: anywhere;
}
.stock-position-value {
  display: block;
  color: #24455f;
  font-size: 14px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.stock-position-asof,
.stock-position-origin {
  display: block;
  color: #526a80;
  font-size: 12px;
  margin-top: 4px;
  line-height: 1.5;
}
.stock-position-issue,
.inventory-admin-issue {
  color: #805518;
  font-size: 13px;
  line-height: 1.5;
  margin: 8px 0 0;
}
.stock-position-mode-note {
  color: #526a80;
  font-size: 13px;
  margin: 0 0 16px;
}
.stock-position-mode-note.attention {
  color: #805518;
  background: #fff9eb;
  border: 1px solid #eed7a8;
  border-radius: 8px;
  padding: 12px;
}
.stock-mobile-values .stock-position-value {
  font-size: 18px;
}
.stock-position-details {
  margin: 16px 0;
  white-space: normal;
}
.stock-position-details h4 {
  font-size: 14px;
  margin: 0 0 12px;
}
.stock-position-balance,
.inventory-admin-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin: 0 0 16px;
}
.stock-position-balance > div {
  background: #f5f9fc;
  padding: 12px;
  border: 1px solid #e0eaf2;
  border-radius: 8px;
}
.stock-position-balance dt,
.inventory-admin-facts dt {
  color: #526a80;
  font-size: 12px;
  margin-bottom: 4px;
}
.stock-position-balance dd,
.inventory-admin-facts dd {
  margin: 0;
  font-size: 14px;
  color: #24455f;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.stock-position-balance small,
.inventory-admin-facts small,
.stock-position-check-time,
.stock-position-legacy,
.inventory-admin-note {
  color: #526a80;
  font-size: 12px;
  line-height: 1.6;
}
.stock-movement-list {
  margin: 12px 0;
}
.stock-movement-list > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 8px 0;
  border-bottom: 1px solid #e4edf4;
}
.stock-movement-list dt {
  color: #526a80;
}
.stock-movement-list dd {
  margin: 0;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.inventory-admin-toolbar,
.inventory-admin-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin: 16px 0;
}
.inventory-admin-toolbar .field {
  flex: 1 1 200px;
  max-width: 360px;
  margin: 0;
}
.inventory-admin-toolbar p {
  color: #526a80;
  margin: 0;
}
.inventory-admin-confirmation {
  padding: 16px;
  border: 1px solid #c8e1f7;
  border-radius: 8px;
  background: #f2f8fe;
  margin: 16px 0;
}
.inventory-admin-confirmation > p {
  margin: 8px 0 12px;
}
@media (max-width: 540px) {
  .stock-position-balance,
  .inventory-admin-facts {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }
  .inventory-admin-toolbar .field,
  .inventory-admin-actions button {
    width: 100%;
    max-width: none;
  }
  .inventory-admin-actions button {
    white-space: normal;
  }
}
