body:has([data-akre-sales]) .select-none.w-full:has(> header h1) {
  display: none;
}
.sales-page {
  padding: 16px 12px 24px;
  color: #0f172a;
  font-size: 15px;
}
.sales-page * {
  box-sizing: border-box;
}
.sales-stock-summary { margin-bottom: 24px; }
.sales-stock-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 0; }
.sales-stock-card { padding: 18px 20px; border: 1px solid #ffedd5; border-radius: 16px; background: white; }
.sales-stock-card dt { font-size: 14px; font-weight: 600; color: #475569; }
.sales-stock-card dd { margin: 8px 0 4px; font-size: clamp(24px, 2.7vw, 34px); font-weight: 600; color: #0f172a; font-variant-numeric: tabular-nums; }
.sales-stock-card p { margin: 0; font-size: 12px; color: #64748b; }
.sales-stock-summary-note { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 10px; }
.sales-stock-summary-note p { margin: 0; font-size: 12px; color: #64748b; }
.sales-stock-summary-note button { padding: 7px 12px; font-size: 12px; }
@media (max-width: 900px) { .sales-stock-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .sales-stock-card { padding: 14px; } .sales-stock-summary-note { align-items: flex-start; flex-direction: column; } }
.sales-heading,
.sales-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}
.sales-page h1 {
  font-size: 30px;
  font-weight: 600;
  line-height: 1.2;
  margin: 5px 0 10px;
}
.sales-page h2 {
  font-size: 23px;
  font-weight: 600;
  margin-bottom: 22px;
}
.sales-page h3 {
  font-size: 18px;
  font-weight: 600;
}
.sales-page p {
  line-height: 1.6;
}
.sales-eyebrow {
  color: #ff6f14;
  font-size: 11px;
  letter-spacing: 0.18em;
  font-weight: 700;
}
.sales-page button {
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 12px 16px;
  background: white;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}
.sales-page button:hover {
  background: #fff7ed;
  border-color: #ff6f14;
}
.sales-page button.sales-primary {
  background: #ff6f14;
  border-color: #ff6f14;
  color: white;
}
.sales-page button.sales-primary:hover {
  background: #ea5a00;
}
.sales-page button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}
.sales-page :is(button, input, select, textarea):focus-visible {
  outline: 3px solid #f8ac66;
  outline-offset: 3px;
}
.sales-page label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 13px;
  font-weight: 600;
  min-width: 0;
}
.sales-page :is(input, select, textarea) {
  width: 100%;
  border: 1px solid #cbd5e1;
  background: white;
  border-radius: 8px;
  padding: 11px 12px;
  font-size: 16px;
  color: #0f172a;
  min-height: 45px;
  font-weight: 400;
}
.sales-page textarea {
  resize: vertical;
}
.sales-form {
  border: 1px solid #ffedd5;
  border-radius: 24px;
  padding: 24px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 18px 50px rgba(89, 56, 24, 0.08);
}
.sales-form fieldset {
  border: 0;
  padding: 0;
  min-width: 0;
}
.sales-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}
.sales-quantity {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: 20px;
  padding: 20px;
  display: grid;
  grid-template-columns: minmax(180px, 1fr) 1.5fr;
  gap: 24px;
  align-items: center;
  margin: 28px 0;
}
.sales-quantity input {
  font-size: 20px;
  font-weight: 600;
}
.sales-quantity p {
  font-size: 13px;
  margin: 6px 0;
}
.sales-quantity button {
  padding: 6px 12px;
}
.sales-section-heading p {
  font-size: 13px;
  color: #64748b;
}
.sales-line {
  display: grid;
  grid-template-columns:
    minmax(190px, 2fr) minmax(95px, 1fr) minmax(90px, 1fr)
    minmax(90px, 1fr) auto;
  align-items: end;
  gap: 12px;
  padding: 18px 0;
  border-top: 1px solid #e2e8f0;
}
.sales-line button {
  margin-bottom: 1px;
}
.sales-wide {
  margin-top: 22px;
}
.sales-empty-lines,
.sales-note {
  color: #64748b;
  font-size: 13px;
}
.sales-actions,
.sales-pagination {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 22px;
}
.sales-note {
  margin-top: 20px;
}
.sales-filters {
  display: grid;
  grid-template-columns: minmax(220px, 2fr) repeat(3, minmax(140px, 1fr));
  gap: 16px;
  padding: 20px;
  background: #f8fafc;
  border-radius: 20px;
  margin-bottom: 18px;
}
.sales-count {
  margin: 10px 0;
  color: #64748b;
}
.sales-table-wrap {
  overflow-x: auto;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
}
.sales-page table {
  border-collapse: collapse;
  width: 100%;
  min-width: 740px;
  text-align: left;
}
.sales-page th {
  background: #f8fafc;
  font-size: 12px;
  color: #64748b;
  font-weight: 600;
  padding: 14px;
}
.sales-page td {
  padding: 17px 14px;
  border-top: 1px solid #e2e8f0;
  vertical-align: top;
  font-size: 14px;
}
.sales-page small {
  display: block;
  font-size: 12px;
  color: #64748b;
  margin-top: 6px;
}
.sales-empty {
  padding: 40px 24px;
  text-align: center;
  border: 1px dashed #fed7aa;
  border-radius: 16px;
}
.sales-empty h2 {
  margin-bottom: 8px;
}
.sales-pagination {
  justify-content: flex-end;
  font-size: 13px;
}
.sales-error,
.sales-success {
  padding: 14px 18px;
  border-radius: 10px;
  margin: 16px 0;
}
.sales-error {
  color: #862b27;
  background: #fff0ed;
  border: 1px solid #edc4bd;
}
.sales-success {
  color: #245b34;
  background: #edf7ed;
  border: 1px solid #bfdabe;
}
.sales-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}
.sales-stage-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 12px 0;
}
.sales-stage-actions button,
.sales-stage-done {
  padding: 8px 12px;
  font-size: 13px;
}
.sales-stage-done {
  border-radius: 12px;
  background: #fff7ed;
  color: #0f172a;
  font-weight: 600;
}
.sales-stage-done small {
  margin-top: 2px;
  font-weight: 400;
}
.sales-corrections {
  margin: 8px 0 20px;
  font-size: 13px;
}
.sales-corrections summary {
  cursor: pointer;
  color: #64748b;
}
.sales-page td:last-child {
  min-width: 230px;
}
.sales-allocation {
  padding: 20px;
  margin: 20px 0;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: 20px;
}
.sales-allocation-row {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(220px, 2fr) minmax(
      100px,
      1fr
    ) auto;
  gap: 12px;
  align-items: end;
  border-top: 1px solid #fed7aa;
  padding: 18px 0 4px;
}
.sales-allocation-detail {
  grid-column: 1 / -1;
  margin: 0 0 12px;
}
.sales-order-details {
  margin: 24px 0;
}
.sales-order-details .sales-table-wrap {
  margin-top: 12px;
}
.sales-order-details table {
  min-width: 400px;
}
.sales-order-details td:last-child {
  min-width: 0;
}
.sales-close-order {
  margin-top: 18px;
}
@media (max-width: 900px) {
  .sales-allocation-row {
    grid-template-columns: 1fr;
  }
  .sales-allocation-row button {
    justify-self: start;
  }
}
@media (max-width: 1100px) {
  .sales-line {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sales-line button {
    justify-self: start;
  }
}
@media (max-width: 600px) {
  .sales-heading,
  .sales-section-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }
  .sales-form {
    padding: 18px 14px;
  }
  .sales-fields,
  .sales-quantity,
  .sales-filters {
    grid-template-columns: 1fr;
  }
  .sales-quantity {
    padding: 16px;
    gap: 12px;
  }
  .sales-page h1 {
    font-size: 28px;
  }
  .sales-page {
    padding: 20px 0;
  }
  .sales-line {
    column-gap: 10px;
  }
  .sales-line > label:first-child {
    grid-column: 1 / -1;
  }
}

/* Reuse the original production page-header and panel treatment. */
.sales-heading {
  min-height: 88px;
  padding: 20px;
  border: 1px solid rgba(255, 237, 213, 0.8);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 16px 40px rgba(89, 56, 24, 0.08);
}
.sales-heading p {
  color: #64748b;
}
.sales-page :is(button, input, select, textarea) {
  font-family: inherit;
}
.sales-eyebrow {
  letter-spacing: 0.28em;
  font-weight: 600;
}
.sales-table-wrap {
  background: white;
  box-shadow: 0 18px 50px rgba(89, 56, 24, 0.08);
}
.sales-page th {
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
.sales-page tbody tr:nth-child(even) {
  background: rgba(248, 250, 252, 0.8);
}
.sales-empty {
  background: rgba(255, 247, 237, 0.6);
}
@media (min-width: 640px) {
  .sales-page {
    padding-left: 24px;
    padding-right: 24px;
  }
}

/* A focusable wrapper lets disabled native buttons explain their blocker. */
.sales-button-help { position: relative; display: inline-flex; max-width: 100%; }
.sales-button-help[data-disabled] { cursor: not-allowed; }
.sales-button-help > button:disabled { pointer-events: none; }
.sales-button-help:focus-visible { outline: 2px solid #c96b32; outline-offset: 3px; border-radius: 8px; }
.sales-button-tooltip { display: none; position: absolute; z-index: 20; bottom: calc(100% + 8px); left: 0; width: max-content; max-width: min(320px, 80vw); padding: 8px 12px; border-radius: 8px; background: #334155; color: white; font-size: 13px; font-weight: 400; line-height: 1.4; white-space: normal; box-shadow: 0 3px 12px #0002; }
.sales-button-help:hover > .sales-button-tooltip, .sales-button-help:focus > .sales-button-tooltip { display: block; }
.sales-allocation-blockers { margin: 12px 0; padding: 12px 16px; border: 1px solid #e6bb91; border-radius: 8px; background: #fff7ed; color: #713f12; }
.sales-allocation-blockers ul { margin: 6px 0 0; padding-left: 20px; list-style: disc; }

@media (min-width: 601px) and (max-width: 1100px) { .sales-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
