/* Stockroom HTML dashboard template. Ownership and license: LICENSE.md at the package root. Browser-only examples. */
@font-face {
  font-family: Inter;
  src: url("../fonts/InterVariable.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}
.table-wrap {
  position: relative;
}
:root {
  color-scheme: light;
  --bg: #f5f7fa;
  --surface: #fff;
  --text: #101d30;
  --muted: #62718a;
  --border: #e4eaf0;
  --primary: #006861;
  --teal: #009e92;
  --soft: #e5f5f1;
  --sidebar: #12292c;
  --shadow: 0 4px 18px #17364706;
  --radius: 11px;
  --sidebar-width: 246px;
  --space: 28px;
  --font: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --danger: #a62737;
  --warning: #985200;
  --success: #087946;
  --row: 60px;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0d1c22;
  --surface: #15282f;
  --text: #edf3f5;
  --muted: #a1b5c5;
  --border: #294049;
  --primary: #65ddca;
  --teal: #4ec8ba;
  --soft: #1c403d;
  --shadow: none;
  --danger: #ffa4af;
  --warning: #ffca79;
  --success: #8ce3b3;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.55 var(--font);
}
a {
  color: var(--primary);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
select,
summary {
  cursor: pointer;
}
button,
a,
input,
select,
textarea {
  touch-action: manipulation;
}
button {
  color: inherit;
}
button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid #27a99d;
  outline-offset: 3px;
}
button {
  border: 0;
  background: transparent;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font-size: 30px;
  letter-spacing: -1px;
  line-height: 1.2;
  margin-bottom: 6px;
  font-weight: 750;
}
h2 {
  font-size: 18px;
  letter-spacing: -0.4px;
  line-height: 1.3;
  margin-bottom: 4px;
}
h3 {
  font-size: 15px;
  margin-bottom: 8px;
}
p {
  color: var(--muted);
  margin-bottom: 16px;
}
svg.icon {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 1.7;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
  vertical-align: middle;
}
img {
  max-width: 100%;
}
small,
.small {
  font-size: 12px;
}
.muted {
  color: var(--muted);
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
[hidden] {
  display: none !important;
}
.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  transform: translateY(-180%);
  z-index: 100;
  background: var(--surface);
  padding: 10px;
}
.skip-link:focus {
  transform: none;
}
.sidebar {
  width: var(--sidebar-width);
  position: fixed;
  inset: 0 auto 0 0;
  background: var(--sidebar);
  color: #dce9eb;
  display: flex;
  flex-direction: column;
  padding: 24px 12px 16px;
  z-index: 30;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #fff;
  font-size: 25px;
  font-weight: 700;
  letter-spacing: -0.6px;
  padding: 0 10px;
  margin-bottom: 28px;
}
.brand:hover {
  text-decoration: none;
}
.workspace-wrap {
  position: relative;
  margin: 0 7px 26px;
  border: 1px solid #345156;
  border-radius: 7px;
  padding: 7px 12px 8px;
}
.workspace-wrap select {
  width: 100%;
  border: 0;
  background: var(--sidebar);
  color: #f4ffff;
  padding: 2px 18px 0 0;
  font-weight: 600;
  outline-offset: 6px;
}
.workspace-wrap small {
  color: #adbec7;
  display: block;
  margin-top: 2px;
}
.nav-label {
  font-size: 11px;
  letter-spacing: 0.7px;
  color: #9bb5bf;
  margin: 0 12px 10px;
}
.nav-link {
  display: flex;
  align-items: center;
  gap: 16px;
  color: #dbe6ee;
  min-height: 46px;
  padding: 10px 15px;
  border-radius: 6px;
  margin-bottom: 4px;
  position: relative;
}
.nav-link:hover {
  background: #ffffff0b;
  text-decoration: none;
}
.nav-link.active {
  background: #1a4e4c;
  color: #fff;
  font-weight: 600;
}
.nav-link.active:before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  bottom: 8px;
  width: 3px;
  background: #7de6d8;
  border-radius: 3px;
}
.nav-count {
  margin-left: auto;
  border-radius: 20px;
  background: #39706e;
  color: #e6fffa;
  padding: 0 8px;
  font-size: 12px;
}
.nav-count:empty {
  display: none;
}
.sidebar-bottom {
  margin-top: auto;
  border-top: 1px solid #345156;
  padding-top: 14px;
}
.owner {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 10px 0;
  color: #eef7fa;
}
.owner:hover {
  text-decoration: none;
}
.owner small {
  display: block;
  color: #a9c0cb;
}
.owner .icon {
  margin-left: auto;
}
.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #dce7ec;
  color: #31536a;
  font-weight: 600;
  flex-shrink: 0;
  overflow: hidden;
}
.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.owner .avatar {
  background: #326576;
  color: #e5faff;
}
.avatar-small {
  width: 32px;
  height: 32px;
  font-size: 11px;
}
.app {
  margin-left: var(--sidebar-width);
  min-width: 0;
}
.topbar {
  height: 72px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 0 var(--space);
  position: relative;
  z-index: 20;
}
.breadcrumb {
  display: flex;
  gap: 13px;
  white-space: nowrap;
  color: var(--muted);
}
.breadcrumb a {
  color: var(--muted);
}
.breadcrumb span:last-child {
  color: var(--text);
}
.global-search {
  margin-left: auto;
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 510px;
  flex: 1;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--bg);
  padding: 7px 10px;
  color: var(--muted);
}
.global-search input {
  border: 0;
  padding: 0;
  outline: none;
  background: transparent;
  min-width: 0;
  width: 100%;
  color: var(--text);
}
kbd {
  border: 1px solid var(--border);
  border-radius: 3px;
  font-size: 11px;
  white-space: nowrap;
  padding: 0 4px;
  color: var(--muted);
}
.top-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.icon-button {
  display: inline-flex;
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  position: relative;
  color: var(--muted);
}
.icon-button:hover {
  background: var(--bg);
  text-decoration: none;
}
.unread-dot {
  position: absolute;
  right: 7px;
  top: 6px;
  background: #df654c;
  border: 2px solid var(--surface);
  width: 9px;
  height: 9px;
  border-radius: 50%;
}
.menu-wrap {
  position: relative;
}
.popover {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 10px 36px #06151f20;
  padding: 8px;
  min-width: 210px;
  z-index: 50;
}
.popover a,
.popover > button {
  display: block;
  text-align: left;
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  color: var(--text);
}
.popover a:hover,
.popover > button:hover {
  background: var(--bg);
  text-decoration: none;
}
.search-results {
  left: 0;
  right: 0;
  max-height: 400px;
  overflow: auto;
}
.search-results small {
  display: block;
}
.search-results h3 {
  margin: 8px 10px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}
.notifications {
  width: 320px;
  max-width: calc(100vw - 30px);
}
.notification {
  border-bottom: 1px solid var(--border);
  padding: 12px;
}
.notification p {
  font-size: 12px;
  margin: 2px 0;
}
.notification a {
  padding: 0;
  font-weight: 600;
}
.mobile-menu {
  display: none;
}
main {
  padding: 30px var(--space) 18px;
  max-width: 1800px;
  margin: auto;
}
.page-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 25px;
}
.page-heading p {
  margin: 0;
  font-size: 14px;
}
.page-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 14px;
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
  font-weight: 550;
  line-height: 1.4;
  white-space: nowrap;
}
.btn:hover {
  background: var(--bg);
  text-decoration: none;
}
.btn.primary {
  background: #00645e;
  border-color: #00645e;
  color: white;
}
.btn.primary:hover {
  background: #00544e;
}
.btn.danger {
  color: var(--danger);
  border-color: var(--danger);
}
.btn.small {
  font-size: 12px;
  min-height: 34px;
  padding: 6px 10px;
}
.card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  min-width: 0;
  padding: 20px;
}
.card-header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}
.card-header p {
  font-size: 13px;
  margin: 3px 0 0;
}
.text-link {
  font-size: 12px;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.text-link .icon {
  width: 15px;
  height: 15px;
}
.kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}
.kpi {
  position: relative;
  overflow: hidden;
  padding: 20px;
  min-height: 136px;
}
.kpi-title {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 14px;
}
.kpi-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 35px;
  height: 35px;
  background: var(--soft);
  color: var(--primary);
  border-radius: 8px;
}
.kpi-value {
  font-size: 29px;
  letter-spacing: -0.8px;
  font-weight: 750;
  line-height: 1.1;
  position: relative;
  z-index: 1;
}
.kpi-note {
  font-size: 11px;
  color: var(--success);
  margin-top: 8px;
}
.kpi-spark {
  position: absolute;
  right: 15px;
  bottom: 24px;
  width: 85px;
  height: 46px;
  color: var(--teal);
  opacity: 0.85;
}
.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(290px, 1fr);
  gap: 20px;
  margin-bottom: 20px;
}
.segmented {
  display: flex;
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  flex-shrink: 0;
}
.segmented button {
  font-size: 12px;
  color: var(--muted);
  padding: 8px 11px;
  border-right: 1px solid var(--border);
}
.segmented button:last-child {
  border: 0;
}
.segmented button.active {
  background: #00645e;
  color: white;
}
.chart-total {
  font-size: 31px;
  font-weight: 750;
  letter-spacing: -0.7px;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 15px;
}
.chart-total small {
  font-weight: 400;
  font-size: 11px;
  letter-spacing: 0;
  color: var(--muted);
}
.chart {
  width: 100%;
  height: 220px;
  display: block;
  overflow: visible;
}
.chart text {
  fill: var(--muted);
  font-family: var(--font);
  font-size: 11px;
}
.chart line {
  stroke: var(--border);
}
.chart .area {
  fill: var(--teal);
  fill-opacity: 0.09;
}
.chart .line {
  fill: none;
  stroke: var(--teal);
  stroke-width: 2.5;
}
.chart-point {
  fill: var(--teal);
  stroke: var(--surface);
  stroke-width: 2;
  cursor: help;
}
.chart-point:focus {
  outline: none;
  stroke: var(--text);
  stroke-width: 4;
}
.chart-caption {
  font-size: 11px;
  color: var(--muted);
  margin-top: 8px;
}
.inventory-total {
  font-size: 31px;
  font-weight: 700;
  line-height: 1.1;
}
.stock-bar {
  display: flex;
  gap: 2px;
  height: 15px;
  border-radius: 20px;
  overflow: hidden;
  margin: 18px 0;
}
.stock-bar > span {
  min-width: 0;
}
.stock-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
.stock-row strong {
  margin-left: auto;
}
.stock-row small {
  width: 35px;
  text-align: right;
  color: var(--muted);
}
.dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--teal);
  flex: none;
}
.dot.amber {
  background: #f7b830;
}
.dot.gray {
  background: #bbcad5;
}
.stock-alert {
  display: flex;
  gap: 10px;
  align-items: center;
  background: #fff4dd;
  color: #935000;
  border: 1px solid #f6e4b9;
  border-radius: 6px;
  padding: 10px 12px;
  margin-top: 18px;
  font-size: 12px;
  font-weight: 600;
}
.stock-alert:hover {
  background: #ffedc5;
  text-decoration: none;
}
.table-wrap {
  overflow: auto;
  max-width: 100%;
  border-radius: 7px;
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  white-space: nowrap;
  font-size: 13px;
}
th {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  background: var(--bg);
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
td {
  padding: 12px;
  height: var(--row);
  border-bottom: 1px solid var(--border);
}
tbody tr:last-child td {
  border-bottom: 0;
}
th button {
  font-size: inherit;
  color: inherit;
  font-weight: inherit;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0;
}
th button:hover {
  color: var(--primary);
}
td.amount,
th.amount {
  text-align: right;
}
.cell-person,
.cell-product {
  display: flex;
  align-items: center;
  gap: 10px;
}
.cell-person .avatar {
  width: 30px;
  height: 30px;
  font-size: 10px;
}
.cell-product img {
  width: 38px;
  height: 38px;
  border-radius: 7px;
}
.cell-product small {
  display: block;
  color: var(--muted);
}
.pill {
  display: inline-block;
  font-size: 11px;
  line-height: 1.5;
  padding: 3px 9px;
  border-radius: 16px;
  white-space: nowrap;
  background: var(--bg);
  color: var(--muted);
  font-weight: 600;
}
.pill.paid,
.pill.delivered,
.pill.in-stock,
.pill.active {
  background: #e0f6e7;
  color: #067441;
}
.pill.processing,
.pill.low-stock {
  background: #fff1cf;
  color: #925000;
}
.pill.shipped {
  background: #e0f0ff;
  color: #14628b;
}
.pill.cancelled,
.pill.out-of-stock,
.pill.refunded,
.pill.archived {
  background: #fae7e9;
  color: #a12d3e;
}
.bestseller {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.bestseller:last-child {
  border: 0;
}
.bestseller img {
  width: 42px;
  height: 42px;
  border-radius: 6px;
}
.bestseller .product-info {
  min-width: 0;
  flex: 1;
}
.bestseller a {
  color: var(--text);
  display: block;
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.bestseller small {
  font-size: 10px;
  color: var(--muted);
}
.progress-track {
  height: 5px;
  border-radius: 5px;
  background: var(--bg);
  margin-top: 7px;
  overflow: hidden;
}
.progress-track span {
  display: block;
  height: 100%;
  background: var(--teal);
  border-radius: 5px;
}
.bestseller .revenue {
  text-align: right;
  font-size: 12px;
  font-weight: 600;
}
.toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.toolbar .search-input {
  flex: 1;
  min-width: 160px;
}
.input,
select.input,
textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  padding: 10px 12px;
  min-height: 42px;
}
.toolbar select {
  width: auto;
  max-width: 100%;
}
.toolbar label {
  font-size: 11px;
  color: var(--muted);
}
.table-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-top: 1px solid var(--border);
  padding-top: 16px;
  margin-top: 12px;
  font-size: 12px;
  color: var(--muted);
  flex-wrap: wrap;
}
.table-footer select {
  width: auto;
  min-height: 32px;
  padding: 3px 7px;
}
.pagination {
  display: flex;
  align-items: center;
  gap: 8px;
}
.selection-summary {
  font-size: 12px;
  color: var(--muted);
  min-height: 20px;
  margin-bottom: 8px;
}
input[type="checkbox"] {
  accent-color: var(--primary);
  width: 16px;
  height: 16px;
}
.row-actions {
  position: relative;
}
.row-actions .popover {
  position: fixed;
  top: auto;
  right: auto;
  min-width: 160px;
}
.empty {
  padding: 45px 20px;
  text-align: center;
}
.empty .icon {
  width: 34px;
  height: 34px;
  color: var(--muted);
  margin-bottom: 12px;
}
.empty p {
  font-size: 13px;
  max-width: 400px;
  margin: 0 auto 18px;
}
.two-columns {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(260px, 1fr);
  gap: 22px;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.field {
  display: block;
}
.field > span {
  display: block;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 7px;
}
.field small {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-top: 5px;
}
.field.full {
  grid-column: 1/-1;
}
.form-error {
  background: #fce9eb;
  border: 1px solid #f4c7cd;
  color: #a32738;
  padding: 10px 12px;
  border-radius: 6px;
  margin-bottom: 16px;
}
.field-error {
  color: var(--danger) !important;
}
.form-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 22px;
  border-top: 1px solid var(--border);
  padding-top: 20px;
}
.form-actions .btn.primary {
  margin-left: auto;
}
textarea {
  min-height: 105px;
  resize: vertical;
}
.image-preview {
  width: 120px;
  height: 120px;
  object-fit: cover;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg);
  margin-bottom: 12px;
}
.detail-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.detail-list dt {
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 4px;
}
.detail-list dd {
  margin: 0;
  overflow-wrap: anywhere;
}
.detail-hero {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 22px;
}
.detail-hero img {
  width: 105px;
  height: 105px;
  border-radius: 12px;
}
.detail-hero h2 {
  font-size: 23px;
}
.detail-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 20px;
}
.timeline {
  list-style: none;
  padding: 0;
  margin: 0;
}
.timeline li {
  border-left: 2px solid var(--border);
  padding: 0 0 20px 20px;
  position: relative;
}
.timeline li:before {
  position: absolute;
  left: -5px;
  top: 5px;
  content: "";
  width: 8px;
  height: 8px;
  background: var(--teal);
  border-radius: 50%;
}
.timeline small {
  display: block;
  color: var(--muted);
}
.summary-line {
  display: flex;
  justify-content: space-between;
  padding: 7px 0;
  gap: 20px;
}
.summary-line.total {
  border-top: 1px solid var(--border);
  font-size: 18px;
  font-weight: 700;
  margin-top: 10px;
  padding-top: 15px;
}
.notice {
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--soft);
  color: var(--primary);
  padding: 13px 16px;
  margin-bottom: 20px;
  font-size: 12px;
}
.notice.warning {
  background: #fff4dd;
  color: #864900;
  border-color: #f0ddb5;
}
.notice a {
  color: inherit;
  text-decoration: underline;
}
.footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 11px;
  color: var(--muted);
  padding-top: 25px;
  flex-wrap: wrap;
}
.footer-dot {
  padding: 0 8px;
}
.toast-region {
  position: fixed;
  right: 24px;
  bottom: 24px;
  display: grid;
  gap: 10px;
  max-width: min(420px, calc(100vw - 32px));
  z-index: 100;
}
.toast {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  padding: 15px 18px;
  box-shadow: 0 4px 30px #071b2520;
  display: flex;
  align-items: center;
  gap: 12px;
}
.toast.error {
  border-color: var(--danger);
}
.toast button {
  margin-left: auto;
}
.toast .icon {
  color: var(--primary);
}
dialog {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  padding: 0;
  width: 520px;
  max-width: calc(100vw - 32px);
  max-height: calc(100dvh - 40px);
  box-shadow: 0 20px 100px #0004;
}
dialog::backdrop {
  background: #051c2866;
  backdrop-filter: blur(2px);
}
.dialog-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
}
.dialog-heading h2 {
  margin: 0;
}
.dialog-body {
  padding: 22px 24px;
}
.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 22px;
}
body.modal-open {
  overflow: hidden;
}
.date-controls {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.date-controls input {
  padding: 8px;
  min-height: 40px;
  font-size: 12px;
  width: 145px;
}
.date-controls label {
  display: flex;
  flex-direction: column;
  font-size: 10px;
  color: var(--muted);
}
.help-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}
.help-grid details {
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 9px;
}
.help-grid summary {
  font-weight: 600;
}
.help-grid p {
  margin: 12px 0 0;
  font-size: 13px;
}
.component-section {
  margin-bottom: 20px;
}
.component-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.auth-layout {
  max-width: 460px;
  margin: 35px auto 60px;
}
.auth-layout .card {
  padding: 30px;
}
.auth-layout .field {
  margin-bottom: 18px;
}
.auth-layout .btn {
  width: 100%;
  margin-top: 4px;
}
.auth-layout p {
  font-size: 13px;
}
.auth-layout .auth-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 25px;
  font-size: 24px;
  font-weight: 700;
}
.auth-brand img {
  width: 38px;
}
.auth-layout .notice {
  margin-top: 20px;
}
.document-block {
  max-width: 900px;
  margin: 25px auto;
}
.document-block p,
.document-block li {
  font-size: 14px;
}
.document-block h2 {
  margin-top: 28px;
}
.document-block pre {
  overflow: auto;
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 16px;
  border-radius: 7px;
}
.auth-page .sidebar,
.auth-page .topbar,
.auth-page .footer {
  display: none;
}
.auth-page .app {
  margin-left: 0;
}
.auth-page .page-heading {
  max-width: 460px;
  margin: 30px auto 0;
  justify-content: center;
  text-align: center;
}
.danger-zone {
  border-color: #d99ba6;
  margin-top: 20px;
}
.compact {
  --row: 48px;
}
.compact td {
  padding-top: 6px;
  padding-bottom: 6px;
}
.table-card {
  padding: 20px;
}
.metric-footnote {
  font-size: 11px;
  margin: 8px 0 0;
}
.result-count {
  font-size: 12px;
  color: var(--muted);
}
.stack {
  display: grid;
  gap: 20px;
}
.stock-low {
  color: var(--warning);
  font-weight: 700;
}
.print-heading {
  display: none;
}
.inline-checkbox {
  display: flex;
  gap: 10px;
  align-items: center;
}
.file-input {
  max-width: 100%;
  font-size: 12px;
}
.test-indicator {
  display: inline-flex;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--teal);
  margin-right: 6px;
}
.product-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}
.product-cell small {
  display: block;
  color: var(--muted);
}
.product-cell img {
  width: 42px;
  height: 42px;
  border-radius: 7px;
}
.product-cell > div {
  min-width: 0;
}
.detail-list > div {
  min-width: 0;
}
.detail-list dt {
  grid-column: 1;
}
.detail-list dd {
  grid-column: 2;
}
.stack > .card + .card {
  margin-top: 0;
}
#content > .card + .card {
  margin-top: 18px;
}
.pill.needs-attention {
  background: #fff1cf;
  color: #925000;
}
.kpi {
  min-height: 136px;
}
.kpi-note {
  max-width: calc(100% - 60px);
}
.chart {
  height: 210px;
}
@media (min-width: 1600px) {
  :root {
    --space: 36px;
  }
  .chart {
    height: 250px;
  }
  .kpi-value {
    font-size: 34px;
  }
  .kpi {
    min-height: 150px;
  }
}
@media (max-width: 1200px) {
  :root {
    --sidebar-width: 216px;
    --space: 22px;
  }
  .brand {
    font-size: 22px;
  }
  .topbar {
    gap: 15px;
  }
  .global-search {
    max-width: 350px;
  }
  .kpi {
    padding: 17px;
  }
  .kpi-spark {
    width: 55px;
    opacity: 0.5;
  }
  .kpi-title {
    gap: 8px;
    font-size: 11px;
  }
  .dashboard-grid {
    grid-template-columns: minmax(0, 1.5fr) minmax(260px, 1fr);
  }
  .chart-total small {
    display: none;
  }
  .card {
    padding: 17px;
  }
  .page-heading {
    align-items: flex-start;
  }
  .page-actions {
    justify-content: flex-end;
  }
  .date-controls input {
    width: 134px;
  }
}
@media (max-width: 1000px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
  .kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .two-columns {
    grid-template-columns: 1fr;
  }
  .breadcrumb {
    display: none;
  }
  .global-search {
    max-width: none;
  }
  .kpi-spark {
    width: 90px;
  }
  .page-heading {
    flex-direction: column;
  }
  .page-actions {
    justify-content: flex-start;
  }
  .stock-row {
    padding: 8px 0;
  }
  .inventory-card {
    min-height: 270px;
  }
}
@media (max-width: 767px) {
  :root {
    --space: 18px;
  }
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.18s ease;
    width: 250px;
  }
  .sidebar.open {
    transform: translateX(0);
  }
  .sidebar-overlay {
    position: fixed;
    inset: 0;
    background: #071b2866;
    z-index: 29;
  }
  .app {
    margin-left: 0;
  }
  .mobile-menu {
    display: flex;
    flex-shrink: 0;
  }
  .topbar {
    height: 66px;
    padding: 0 14px;
    gap: 8px;
  }
  .top-actions {
    gap: 2px;
  }
  .top-actions > a {
    display: none;
  }
  .global-search {
    padding: 8px;
    gap: 5px;
  }
  .global-search input {
    font-size: 12px;
  }
  .global-search kbd {
    display: none;
  }
  .global-search .icon {
    width: 16px;
  }
  .top-actions .avatar {
    width: 30px;
    height: 30px;
  }
  .notifications {
    position: fixed;
    top: 68px;
    right: 12px;
  }
  .search-results {
    position: fixed;
    top: 66px;
    left: 12px;
    right: 12px;
  }
  .kpis {
    gap: 10px;
    margin-bottom: 16px;
  }
  .kpi {
    padding: 14px;
    min-height: 132px;
  }
  .kpi-title {
    font-size: 11px;
    gap: 7px;
  }
  .kpi-icon {
    width: 28px;
    height: 28px;
  }
  .kpi-value {
    font-size: 25px;
  }
  .kpi-spark {
    width: 48px;
    bottom: 24px;
    right: 8px;
    opacity: 0.35;
  }
  .kpi-note {
    font-size: 10px;
    max-width: 110px;
  }
  .dashboard-grid {
    gap: 16px;
    margin-bottom: 16px;
  }
  h1 {
    font-size: 27px;
  }
  .page-heading p {
    font-size: 13px;
  }
  .page-heading {
    margin-bottom: 20px;
  }
  .card-header {
    gap: 10px;
  }
  .card-header h2 {
    font-size: 16px;
  }
  .segmented button {
    padding: 7px;
    font-size: 11px;
  }
  .chart-total {
    font-size: 28px;
  }
  .chart {
    height: 200px;
  }
  .card {
    padding: 16px;
  }
  .form-grid,
  .help-grid {
    grid-template-columns: 1fr;
  }
  .detail-list {
    grid-template-columns: 1fr 1fr;
  }
  .field.full {
    grid-column: auto;
  }
  .date-controls {
    gap: 6px;
  }
  .date-controls input {
    width: 132px;
  }
  .date-controls .btn {
    align-self: flex-end;
  }
  .page-actions > .btn {
    font-size: 12px;
  }
  .toolbar {
    gap: 8px;
  }
  .toolbar .search-input {
    min-width: 100%;
  }
  .toolbar select {
    flex: 1;
    font-size: 12px;
  }
  .footer {
    font-size: 10px;
  }
  .detail-hero {
    gap: 12px;
  }
  .detail-hero h2 {
    font-size: 20px;
  }
  .detail-hero img {
    width: 80px;
    height: 80px;
  }
  .auth-layout {
    margin-top: 18px;
  }
  .auth-layout .card {
    padding: 22px;
  }
  .auth-page main {
    padding-top: 15px;
  }
  .auth-page .page-heading {
    margin-top: 20px;
  }
  .btn {
    min-height: 42px;
  }
  td {
    font-size: 12px;
  }
  .table-footer {
    align-items: flex-start;
  }
  .table-footer .pagination {
    width: 100%;
    justify-content: flex-end;
  }
  .form-actions {
    flex-wrap: wrap;
  }
  .form-actions .btn.primary {
    margin-left: 0;
  }
  .dialog-body {
    padding: 18px;
  }
  .dialog-heading {
    padding: 16px 18px;
  }
  .toast-region {
    right: 16px;
    bottom: 16px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
@media print {
  body {
    background: white;
    color: #111;
  }
  .sidebar,
  .topbar,
  .page-heading,
  .footer,
  .detail-actions,
  .toast-region,
  .no-print,
  .skip-link {
    display: none !important;
  }
  .app {
    margin: 0;
  }
  main {
    padding: 0;
  }
  .card {
    box-shadow: none;
    border: 0;
    padding: 10px;
  }
  .two-columns {
    display: block;
  }
  .print-heading {
    display: block;
    border-bottom: 2px solid #111;
    padding-bottom: 15px;
    margin-bottom: 20px;
  }
  table {
    font-size: 11px;
  }
  .pill {
    border: 1px solid #999;
    color: #111 !important;
    background: white !important;
  }
  .timeline {
    display: none;
  }
  a {
    color: #111;
  }
  .table-wrap {
    overflow: visible;
  }
}
