/* Keep the wordmark identical to the machines footer, without an extra asset dependency. */
.wevend-wordmark {
  display: inline-block;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.8px;
  white-space: nowrap;
  color: #5896db;
  background: linear-gradient(110deg, #5896db 15%, #58c014 90%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

:root {
  --navy: #343853;
  --green: #049b5b;
  --ink: #343853;
  --muted: #6b7a93;
  --line: #dfe6ef;
  --paper: #fff;
  --wash: #f5f7fa;
  --shadow: 0 12px 36px #25354a0d;
}
.preview-banner.demo-banner { background: #e8f3ee; border-bottom: 1px solid #b8d7c7; color: #315c47; line-height: 1.7; }
.demo-login-note { border-left: 3px solid var(--green); padding: 12px 14px; background: #edf6f1; border-radius: 0 8px 8px 0; color: #315c47; font-size: 13px; line-height: 1.7; }
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  color: var(--ink);
  font-family: Poppins, "Avenir Next", sans-serif;
  background: radial-gradient(at 90% 0, #eaf6f0, transparent 45%), var(--wash);
  font-size: 14px;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
select,
textarea {
  outline-offset: 3px;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: wait;
  opacity: 0.55;
}
a {
  color: var(--green);
}
.portal-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr) minmax(0, 1fr);
  align-items: center;
  gap: 20px;
  background: var(--navy);
  color: #fff;
  padding: 12px 24px;
  flex-wrap: nowrap;
}
.portal-brand { display: flex; align-items: center; gap: 20px; min-width: 0; }
.portal-date-input { cursor: pointer; }
.flatpickr-calendar.portal-date-calendar { position: fixed; z-index: 1000; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 36px #25354a30; font-family: inherit; max-height: calc(100vh - 16px); overflow-y: auto; }
.portal-date-calendar::before, .portal-date-calendar::after { display: none; }
.portal-date-calendar .flatpickr-day.selected { background: var(--green); border-color: var(--green); }
.portal-date-calendar .flatpickr-day:hover { background: #e8f4ee; border-color: #bad9c9; }
.portal-date-calendar .flatpickr-current-month input.cur-year { min-height: 0; border-radius: 0; box-shadow: none; }
.brand {
  font-size: 30px;
  text-decoration: none;
  font-weight: bold;
  flex-shrink: 0;
  white-space: nowrap;
}
.heading {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 14px;
  justify-content: center;
  text-align: center;
}
.portal-header .eyebrow {
  white-space: nowrap;
  flex-shrink: 0;
}
.portal-header h1 {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 18px;
}
#session-actions {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}
@media (max-width: 1100px) { .portal-header .eyebrow { display: none; } }
.eyebrow {
  font-size: 10px;
  letter-spacing: 1.8px;
  opacity: 0.75;
}
h1 {
  font-size: 22px;
  margin: 4px 0;
}
h2 {
  font-size: 20px;
  margin: 0 0 16px;
}
h3 {
  font-size: 15px;
  margin: 0 0 12px;
}
p {
  line-height: 1.6;
}
.muted,
.meta {
  color: var(--muted);
}
.meta {
  font-size: 12px;
}
.preview-banner {
  background: #fff0c9;
  padding: 10px 32px;
  text-align: center;
}
main {
  max-width: 1600px;
  margin: auto;
  padding: 26px 32px 48px;
}
.notice {
  border: 1px solid #b2dac5;
  background: #eaf7f0;
  border-radius: 10px;
  padding: 13px 18px;
  margin-bottom: 18px;
}
.notice.error {
  border-color: #e9b0b4;
  background: #fff0f0;
  color: #a72e3e;
}
.loading {
  color: var(--muted);
}
.panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 24px;
  box-shadow: var(--shadow);
  margin-bottom: 22px;
}
.login-panel {
  max-width: 460px;
  margin: 7vh auto;
}
.demo-launch-card {
  margin-top: 24px;
  padding: 18px;
  border: 1px solid #cce3d7;
  border-radius: 14px;
  background: radial-gradient(ellipse at top right, #d9eee2, transparent 75%), #f4f9f6;
}
.demo-launch-kicker { color: #32744f; font-size: 10px; font-weight: 800; letter-spacing: 1.4px; }
.demo-launch-description { margin: 8px 0 16px; color: #50675c; font-size: 13px; line-height: 1.6; }
.button.demo-launch {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 13px 16px;
  border: 1px solid #343853;
  border-radius: 10px;
  background: #343853;
  color: #fff;
  text-align: left;
  font-size: 14px;
  box-shadow: 0 4px 12px #3438531a;
}
.button.demo-launch:hover:not(:disabled) { background: #244e40; border-color: #244e40; color: #fff; }
.button.demo-launch:focus-visible { outline: 3px solid #329561; outline-offset: 3px; }
.demo-launch-arrow { font-size: 22px; line-height: 1; color: #a6e0bf; flex-shrink: 0; }
.stack {
  display: grid;
  gap: 16px;
}
.row {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.spread {
  justify-content: space-between;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 18px;
}
.field {
  display: grid;
  gap: 7px;
  flex: 1;
  min-width: 160px;
  font-size: 13px;
  font-weight: 600;
}
input,
select,
textarea {
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 11px 13px;
  min-width: 0;
  background: #fbfcfe;
  color: var(--ink);
  width: 100%;
}
input:focus,
select:focus,
textarea:focus {
  border-color: var(--green);
}
input[type="checkbox"] {
  width: 17px;
  height: 17px;
  accent-color: var(--green);
}
textarea {
  resize: vertical;
  min-height: 90px;
}
.check {
  display: flex;
  gap: 9px;
  align-items: center;
  font-size: 13px;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: white;
  color: var(--ink);
  padding: 10px 16px;
  font-weight: 600;
  white-space: nowrap;
}
.primary {
  background: var(--green);
  border-color: var(--green);
  color: white;
}
.danger {
  color: #b1394c;
  background: #fff8f8;
  border-color: #f1d5da;
}
.portal-header .button {
  background: #ffffff10;
  color: white;
  border-color: #ffffff35;
}
.tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 22px;
  overflow: auto;
}
.tabs button {
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 12px 20px;
  white-space: nowrap;
  background: white;
  color: var(--ink);
  font-weight: 600;
}
.tabs button.active {
  background: var(--navy);
  border-color: var(--navy);
  color: white;
}
.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.toolbar h2 {
  margin: 0;
}
.machine-card {
  border: 1px solid var(--line);
  border-top: 3px solid var(--green);
  border-radius: 13px;
  padding: 20px;
  background: white;
  box-shadow: var(--shadow);
}
.machine-card h3 {
  font-size: 18px;
  margin-bottom: 8px;
}
.machine-card .row {
  margin-top: 18px;
}
.tag {
  font-size: 11px;
  padding: 4px 8px;
  border-radius: 6px;
  background: #edf5f0;
  color: #42735c;
  display: inline-block;
}
.table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: white;
}
table {
  border-collapse: collapse;
  width: 100%;
  text-align: left;
  font-size: 13px;
}
th {
  background: var(--green);
  color: white;
  padding: 13px 16px;
  white-space: nowrap;
}
td {
  padding: 14px 16px;
  border-bottom: 1px solid #edf0f5;
  vertical-align: top;
}
body[data-mode="admin"] td {
  vertical-align: middle;
}
.request-machine-link {
  color: #246846;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.request-machine-link:hover { color: #184f33; }
.request-review-notes { margin: 0; }
.portal-selection-field .dropdown-selector-wrapper { position: relative; min-width: 0; }
.portal-selection-field .dropdown-selector-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbfcfe;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.portal-selection-field .dropdown-selector-button > span:first-child { min-width: 0; overflow-wrap: anywhere; }
.portal-selection-field .dropdown-caret { flex-shrink: 0; }
.portal-selection-field .dropdown-selector-button:hover { background: #edf5f0; }
.portal-selection-field .dropdown-selector-content {
  position: absolute;
  inset: calc(100% + 6px) 0 auto;
  z-index: 5;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: white;
  box-shadow: 0 12px 36px #25364d24;
  overflow: hidden;
}
.portal-selection-field .dropdown-search-container { padding: 10px; border-bottom: 1px solid var(--line); }
.portal-selection-field .dropdown-results-container { max-height: min(240px, 30dvh); overflow-y: auto; overscroll-behavior: contain; }
.portal-selection-field .dropdown-result-item {
  display: block;
  width: 100%;
  padding: 11px 14px;
  border: 0;
  border-bottom: 1px solid #edf0f5;
  background: white;
  color: var(--ink);
  font: inherit;
  text-align: left;
  white-space: normal;
  cursor: pointer;
}
.portal-selection-field .dropdown-result-item:hover,
.portal-selection-field .dropdown-result-item:focus-visible,
.portal-selection-field .dropdown-result-item[aria-pressed="true"] { background: #eef6f1; color: #246846; }
.portal-selection-field .dropdown-result-count { padding: 8px 14px; margin: 0; color: var(--muted); font-size: 12px; }
tr:nth-child(even) {
  background: #f7f9fc;
}
.table-wrap .button {
  padding: 6px 9px;
  font-size: 12px;
}
.catalogue-card {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 16px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.catalogue-card img {
  width: 60px;
  height: 72px;
  object-fit: contain;
}
.planogram-row {
  display: flex;
  gap: 8px;
  margin: 10px 0;
  align-items: stretch;
}
.planogram-item {
  position: relative;
  min-width: 0;
  flex: 1;
  background: #eaf5ef;
  border: 1px solid #e0eae6;
  border-radius: 7px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.planogram-item[data-stock-state="low"] {
  background: #fff5dc;
}
.planogram-item[data-stock-state="empty"] {
  background: #fce7eb;
}
.sold-out {
  position: absolute;
  top: 65px;
  align-self: center;
  transform: rotate(-10deg);
  background: #e36a46;
  border: 2px solid white;
  outline: 1px solid #e36a46;
  border-radius: 3px;
  padding: 2px 6px;
  color: white;
  font-weight: 800;
  font-size: 12px;
}
.planogram-item .selection {
  padding: 5px 8px;
  font-size: 11px;
  font-weight: 700;
}
.planogram-item img {
  height: 85px;
  max-width: 90%;
  object-fit: contain;
  margin: 4px auto 10px;
}
.product-name {
  font-size: 11px;
  font-weight: 600;
  padding: 7px;
  flex: 1;
  background: #fff;
}
.item-values {
  background: var(--navy);
  color: white;
  padding: 3px;
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: 10px;
  flex-wrap: wrap;
}
.item-counts {
  display: flex;
  gap: 1px;
}
.item-count,
.item-price {
  background: white;
  color: #253245;
  border: 1px solid #d6dce5;
  padding: 0 2px;
  line-height: 1.4;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.item-count {
  min-width: 16px;
  text-align: center;
}
.item-price {
  margin-left: auto;
  text-align: right;
}
.stats {
  font-size: 10px;
  background: #fff9dd;
  padding: 4px 7px;
}
.charts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin: 24px 0;
}
.chart-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
  background: #f7faf9;
  border-top: 4px solid #7c9e90;
}
.compliance-title {
  grid-column: 1 / -1;
  margin: 0;
}
.chart-body {
  display: flex;
  gap: 20px;
  align-items: center;
}
.pie {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 8px solid white;
  box-shadow: 0 0 0 1px var(--line);
}
.legend {
  display: grid;
  gap: 6px;
  font-size: 12px;
}
.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 7px;
}
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: fit-content;
  max-width: 100%;
  margin: 24px 0 0 auto;
  padding: 7px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 4px 16px #25354a08;
}
.sales-summary {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 12px;
}
.sales-filters { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: end; }
.sales-table-toolbar { margin-top: 24px; }
.sales-table-toolbar h2 { margin-bottom: 4px; }
.sales-filters input:disabled { opacity: 1; color: var(--navy); background: #edf1f5; cursor: not-allowed; }
.sales-group-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 12px 0; }
.sales-group-controls .meta { margin: 0 auto 0 0; }
.sales-group-controls .button { padding: 8px 12px; }
.portal-sales-table tr[hidden] { display: none; }
.portal-sales-table .sales-group-toggle { display: inline-flex; align-items: center; gap: 10px; background: transparent; border: 1px solid #ffffff55; color: #fff; padding: 7px 10px; text-align: left; }
.portal-sales-table .sales-group-toggle:hover { background: #ffffff20; }
.portal-sales-table .sales-group-toggle:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.sales-group-toggle::before { content: ""; width: 7px; height: 7px; flex: 0 0 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); }
.sales-group-toggle[aria-expanded="false"]::before { transform: rotate(-45deg); }
.portal-sales-table .sales-number { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.portal-sales-table .sales-product { min-width: 210px; }
.portal-sales-table .sales-row-group th { background: var(--navy); color: #fff; padding: 14px 18px; }
.portal-sales-table .sales-row-group[data-depth="1"] th { background: #426a62; padding-left: 30px; }
.portal-sales-table .sales-row-subtotal > * { background: #e8f4ee; color: var(--navy); font-weight: 700; border-top: 1px solid #bad9c9; }
.portal-sales-table .sales-row-grand_total > * { background: var(--navy); color: #fff; font-weight: 700; padding: 18px; }
.portal-sales-table .sales-group-label { text-align: left; }
@media (max-width: 700px) { .sales-filters { grid-template-columns: minmax(0, 1fr); } }
.sales-total {
  grid-column: span 3;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--muted);
  font-size: 12px;
}
.sales-total strong {
  color: var(--navy);
  font-size: 22px;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.sales-total-primary {
  grid-column: span 4;
  background: linear-gradient(125deg, #fff, #eef6f2);
  border-top: 3px solid #4a9870;
}
.sales-total-primary strong {
  font-size: 30px;
}
.sales-basis {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
  margin: 16px 0 24px;
}
.sales-chart {
  margin-bottom: 24px;
}
.sales-chart-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.sales-chart-heading h2 {
  margin: 0;
}
.sales-chart-controls {
  display: flex;
  padding: 4px;
  gap: 4px;
  border-radius: 10px;
  background: #edf1f6;
}
.sales-chart-controls .button {
  background: transparent;
  border-color: transparent;
  font-size: 12px;
  padding: 8px 12px;
}
.sales-chart-controls .button[aria-pressed="true"] {
  background: var(--navy);
  color: white;
}
.sales-plot svg {
  display: block;
  width: 100%;
  max-height: 320px;
  margin-top: 18px;
  overflow: visible;
}
.chart-gridline {
  stroke: #e0e7ef;
  stroke-width: 1;
}
.chart-label {
  fill: #66758b;
  font-size: 11px;
}
.chart-area {
  fill: #dceee4;
  opacity: 0.65;
}
.chart-line {
  fill: none;
  stroke: #27815a;
  stroke-width: 2.5;
  stroke-linejoin: round;
}
.chart-marker {
  fill: #fff;
  stroke: #27815a;
  stroke-width: 2;
}
.sales-chart-readout {
  padding: 10px 12px;
  border-radius: 8px;
  background: #f1f6f4;
  color: var(--navy);
  font-size: 12px;
  min-height: 38px;
}
@media (max-width: 800px) {
  .sales-total {
    grid-column: span 6;
  }
  .sales-total-primary {
    grid-column: span 6;
  }
  .sales-total-primary:first-child {
    grid-column: span 12;
  }
  .sales-total {
    padding: 14px;
  }
  .sales-total strong,
  .sales-total-primary strong {
    font-size: 23px;
  }
}
.pagination .button {
  padding: 9px 12px;
  min-height: 40px;
  font-size: 12px;
}
.page-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 4px;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.page-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  height: 30px;
  padding: 0 6px;
  border-radius: 8px;
  background: var(--navy);
  color: #fff;
}
dialog {
  border: 0;
  border-radius: 16px;
  padding: 0;
  width: min(640px, 94vw);
  max-height: 90vh;
  color: var(--ink);
  box-shadow: 0 30px 100px #131c3944;
}
dialog.wide {
  width: min(1300px, 96vw);
}
dialog::backdrop {
  background: #1d233d88;
}
.dialog-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
  background: var(--navy);
  color: white;
  position: sticky;
  top: 0;
  z-index: 2;
}
.dialog-header h2 {
  margin: 0;
  font-size: 19px;
}
.close-button {
  background: white;
  border: 1px solid #dfe3ed;
  color: var(--navy);
  border-radius: 4px;
  width: 30px;
  height: 30px;
  font-size: 26px;
  line-height: 22px;
}
.dialog-content {
  padding: 24px;
}
.close-button {
  transition:
    color 0.15s,
    background 0.15s,
    border-color 0.15s;
  flex-shrink: 0;
}
.close-button:hover,
.close-button:focus-visible {
  background: #dc3545;
  border-color: #dc3545;
  color: white;
}
.portal-header .close-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}
.planogram-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 8px;
  padding: 8px;
  margin: 0 0 16px;
  overflow-x: auto;
  border-radius: 12px;
  background: #f3f6f9;
  border: 1px solid var(--line);
}
.action-group {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  flex-shrink: 0;
}
.planogram-actions svg,
.replace-item svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.planogram-actions .button {
  box-shadow: 0 2px 5px #25354a08;
  flex-shrink: 0;
  padding: 8px 10px;
  font-size: 12px;
  min-height: 36px;
  white-space: nowrap;
}
.replace-item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 7px;
  border: 1px solid #aab2c8;
  border-radius: 7px;
  padding: 8px 4px;
  font-size: 11px;
  color: #343853;
  background: #fff;
  box-shadow: 0 2px 4px #25354a12;
}
.replace-item:hover,
.replace-item:focus-visible {
  background: #343853;
  border-color: #343853;
  color: #fff;
}
.replace-item:focus-visible {
  outline: 2px solid #68749a;
  outline-offset: 2px;
}
.replace-item svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}
.product-choice,
.planogram-item .product-name {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  min-width: 0;
}
.hcg-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  max-width: 100%;
  padding: 3px 7px;
  border: 1px solid #d6dce5;
  border-radius: 5px;
  background: #f2f4f7;
  color: #4d596c;
  font-size: 10px;
  font-weight: 600;
  line-height: 1.4;
}
.planogram-item .product-name > .hcg-badge {
  margin-top: auto;
}
.hcg-badge::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  flex-shrink: 0;
}
.hcg-badge[data-category="green"] {
  background: #eaf6ee;
  border-color: #b9dfc6;
  color: #236b3d;
}
.hcg-badge[data-category="amber"] {
  background: #fff5de;
  border-color: #ecd295;
  color: #805611;
}
.hcg-badge[data-category="amber_sweetener"] {
  background: #fff0df;
  color: #875018;
  border-color: #d6a264;
}
.hcg-badge[data-category="red"] {
  background: #fff0f1;
  border-color: #efbdc4;
  color: #ac3445;
}
.hcg-badge[data-category="na"] {
  background: #eaf3fb;
  border-color: #bad4e9;
  color: #315f82;
}
.catalogue-price {
  font-weight: 600;
  margin: 10px 0 0;
}
.catalogue-filters {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 12px;
}
.catalogue-filters .field:first-child {
  flex: 1 1 260px;
}
.catalogue-filters .field:has(select) {
  flex: 0 1 230px;
}
@media (max-width: 600px) {
  .catalogue-filters .field,
  .catalogue-filters .field:has(select) {
    flex: 1 1 100%;
  }
}
.price-disclaimer {
  color: var(--muted);
  font-size: 12px;
  padding: 12px 16px;
  border-left: 3px solid #86a895;
  background: #edf5f0;
  border-radius: 5px;
}
.form-section {
  background: #f6f9fb;
  border: 1px solid var(--line);
  border-left: 3px solid #83a697;
  border-radius: 12px;
  padding: 18px;
}
.search-list {
  max-height: 240px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.search-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border: 0;
  border-bottom: 1px solid var(--line);
  width: 100%;
  text-align: left;
  background: white;
  color: var(--ink);
}
.search-option:hover,
.search-option:focus {
  background: #eaf5ef;
}
.search-option img {
  width: 30px;
  height: 40px;
  object-fit: contain;
}
.selected-product {
  padding: 10px;
  background: #eaf5ef;
  border-radius: 8px;
}
.conflict {
  background: #fff6df;
  border: 1px solid #ebd39a;
  padding: 16px;
  border-radius: 10px;
}
.qr-image {
  display: block;
  width: 260px;
  max-width: 100%;
  margin: auto;
}
.qr-sticker-preview {
  display: flex;
  justify-content: center;
  padding: 16px 0;
  overflow: auto;
  background: radial-gradient(ellipse at top, #e8f4ec, #f4f6fa);
  border: 1px solid var(--border);
  border-radius: 12px;
}
.qr-sticker-preview .qr-sticker { flex-shrink: 0; box-shadow: 0 8px 24px #24384c18; }
.qr-sticker-controls { margin: 16px 0; }
.empty {
  text-align: center;
  padding: 40px;
  color: var(--muted);
}
[hidden] {
  display: none !important;
}
@media (max-width: 700px) {
  .portal-header {
    padding: 8px 12px;
    gap: 6px;
    grid-template-columns: minmax(96px, 1fr) minmax(0, 2fr) minmax(96px, 1fr);
  }
  .brand {
    font-size: 21px;
  }
  .portal-header .eyebrow {
    display: none;
  }
  .portal-header h1 {
    font-size: 13px;
    margin: 0;
  }
  main {
    padding: 16px;
  }
  .panel {
    padding: 18px;
  }
  .charts {
    grid-template-columns: 1fr;
  }
  .planogram-row {
    min-width: 100%;
    width: max-content;
  }
  .planogram-item {
    flex: 1 0 110px;
    width: 110px;
  }
  .planogram {
    overflow: auto;
  }
  .chart-body {
    gap: 12px;
  }
  .button {
    padding: 10px 12px;
  }
  .grid {
    grid-template-columns: 1fr;
  }
  .portal-header #session-actions {
    width: auto;
  }
  .portal-header .button {
    padding: 8px;
    font-size: 11px;
    min-height: 36px;
    white-space: nowrap;
  }
  .compact-label > .action-label {
    display: none;
  }
  .compact-label::after {
    content: attr(data-short-label);
  }
  .dialog-header {
    padding: 10px 12px;
    gap: 10px;
  }
  .dialog-header h2 {
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 15px;
  }
  .dialog-content {
    padding: 14px;
  }
  .planogram-actions {
    gap: 5px;
    padding: 5px;
  }
  .planogram-actions .action-group {
    gap: 5px;
  }
  .planogram-actions .button {
    padding: 8px;
    gap: 5px;
    font-size: 11px;
  }
  .planogram-actions svg {
    width: 15px;
    height: 15px;
  }
  .tabs button {
    padding: 10px 14px;
  }
}
@media print {
  body {
    background: white;
  }
  .portal-header,
  .tabs,
  .toolbar button,
  #session-actions,
  .preview-banner {
    display: none !important;
  }
  main {
    padding: 0;
  }
  .machine-export {
    break-before: page;
  }
  .machine-export:first-child {
    break-before: auto;
  }
  .planogram-row {
    break-inside: avoid;
  }
  .panel {
    box-shadow: none;
    border: 0;
    padding: 0;
  }
  .charts {
    break-inside: avoid;
  }
  .planogram {
    overflow: visible;
  }
}
.hcg-assessment { grid-column: 1 / -1; padding: 22px 24px; border: 1px solid #d8e2e8; border-left: 5px solid #74849b; border-radius: 16px; background: linear-gradient(120deg, #f6f9fc, #edf3f6); color: #343957; }
.hcg-assessment[data-status="compliant"] { border-left-color: #169763; background: linear-gradient(120deg, #e8f6ef, #f8fcfa); }
.hcg-assessment[data-status="needs_attention"] { border-left-color: #d89b29; background: linear-gradient(120deg, #fff4da, #fffaf0); }
.hcg-assessment-label { text-transform: uppercase; letter-spacing: .12em; font-size: 11px; font-weight: 700; }
.hcg-assessment h3 { margin: 7px 0; font-size: clamp(20px, 3vw, 28px); }
.hcg-target-checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; }
.hcg-target-check { display: flex; flex-direction: column; gap: 5px; padding: 12px; border: 1px solid #d8e6df; border-radius: 10px; background: #ffffffb8; font-size: 13px; }
.hcg-target-check strong { text-transform: capitalize; }
.hcg-target-check small { color: #257047; font-weight: 600; }
.hcg-target-check[data-passed="false"] { border-color: #dfba69; }
.hcg-target-check[data-passed="false"] small { color: #855511; }
.hcg-improvements { padding-left: 20px; margin-bottom: 0; font-size: 14px; }
.hcg-improvements li + li { margin-top: 6px; }
.hcg-settings-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 270px), 1fr)); gap: 20px; margin: 18px 0; }
.hcg-machine-picker[hidden], .hcg-machine-choice[hidden] { display: none; }
.hcg-machine-picker > h3, .hcg-machine-picker > p, .hcg-machine-picker > .toolbar { margin: 0; }
.hcg-machine-picker > .toolbar { justify-content: flex-start; gap: 10px; }
.hcg-machine-list { display: grid; gap: 8px; max-height: 300px; overflow-y: auto; }
.hcg-machine-choice { padding: 12px; margin: 0; border: 1px solid var(--line); border-radius: 10px; background: white; cursor: pointer; flex-wrap: wrap; }
.hcg-machine-choice input { flex: 0 0 auto; }
.hcg-machine-choice.is-selected { border-color: #83a697; background: #edf5f0; }
.hcg-machine-choice:focus-within { outline: 2px solid var(--green); outline-offset: -2px; }
.hcg-machine-details { margin-left: auto; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.hcg-machine-policy { font-size: 12px; color: var(--muted); }

/* Reports and service evidence use the same portal controls and colour palette. */
.report-form-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
.report-form-grid[hidden] { display:none; }
.schedule-list { display:grid; gap:12px; margin-top:20px; }
.schedule-card { display:flex; justify-content:space-between; align-items:center; gap:20px; padding:18px; border:1px solid #dce5ed; border-radius:14px; background:#f8fafc; margin-block:12px; }
.schedule-card h3 { margin:0 0 6px; }
.schedule-card .meta { margin:5px 0; overflow-wrap:anywhere; }
.schedule-card .row { flex-shrink:0; flex-wrap:wrap; }
.schedule-summary { padding:14px 16px; border:1px solid #cce2d5; border-radius:12px; background:#edf6f0; color:#2e634b; line-height:1.6; }
.saved-report-toolbar { border-top:1px solid #dce5ed; padding-top:16px; margin-top:18px; align-items:end; }
.saved-report-toolbar .field { flex:1; }
.sales-report-actions { margin-left:auto; justify-content:flex-end; }
.button.danger { color:#a73c47; border-color:#eed8dc; background:#fff6f7; }
.button.danger:hover { color:#8d2934; border-color:#dfbbc2; background:#fbecef; }
dialog.planogram-fullscreen { inset:0; margin:0; width:100vw; max-width:100vw; height:100dvh; max-height:100dvh; border-radius:0; }
dialog.planogram-fullscreen[open] { display:flex; flex-direction:column; }
.planogram-fullscreen .dialog-header { flex-shrink:0; }
.planogram-fullscreen .dialog-content { flex:1; min-height:0; overflow:auto; }
.service-planogram-layout { display:grid; grid-template-columns:minmax(260px,30%) minmax(0,1fr); gap:24px; align-items:start; }
.service-photo-panel { padding:20px; border:1px solid #dce5ed; border-radius:16px; background:#f8fafc; position:sticky; top:0; }
.service-photo-panel h3 { margin:0 0 16px; }
.service-photo-image { display:block; width:100%; height:auto; max-height:65dvh; object-fit:contain; border-radius:10px; background:white; }
.service-photo-choices { display:flex; gap:8px; flex-wrap:wrap; }
.service-photo-choices .button { padding:7px 10px; font-size:12px; }
.service-photo-choices [aria-pressed="true"] { background:#397658; color:white; border-color:#397658; }
.service-planogram-panel { min-width:0; }
.service-planogram-panel .planogram { overflow:auto; }
.service-planogram-panel .planogram-row { min-width:100%; width:max-content; }
.service-planogram-panel .planogram-item { flex:1 0 110px; width:110px; }
@media(max-width:800px) {
 .service-planogram-layout { grid-template-columns:1fr; }
 .service-photo-panel { position:static; }
 .service-photo-image { max-height:45dvh; }
 .schedule-card { align-items:stretch; flex-direction:column; }
}
@media(max-width:480px) { .report-form-grid { grid-template-columns:1fr; } }
