/* App-specific UI components (loaded after assets/css/style.css). */

html[data-wingu-accent="classic"] {
  --wingu-accent-light-rgb: 254, 159, 67;
  --wingu-accent-dark-rgb: 254, 159, 67;
}

html[data-wingu-accent="orange"] {
  --wingu-accent-light-rgb: 168, 67, 0;
  --wingu-accent-light-hover-rgb: 140, 56, 0;
  --wingu-accent-dark-rgb: 255, 176, 116;
  --wingu-accent-dark-hover-rgb: 243, 154, 74;
}

html[data-wingu-accent="teal"] {
  --wingu-accent-light-rgb: 0, 105, 92;
  --wingu-accent-light-hover-rgb: 0, 77, 64;
  --wingu-accent-dark-rgb: 128, 203, 196;
  --wingu-accent-dark-hover-rgb: 77, 182, 172;
}

html[data-wingu-accent="red"] {
  --wingu-accent-light-rgb: 198, 40, 40;
  --wingu-accent-light-hover-rgb: 183, 28, 28;
  --wingu-accent-dark-rgb: 239, 154, 154;
  --wingu-accent-dark-hover-rgb: 229, 115, 115;
}

html[data-wingu-accent="purple"] {
  --wingu-accent-light-rgb: 94, 53, 177;
  --wingu-accent-light-hover-rgb: 69, 39, 160;
  --wingu-accent-dark-rgb: 179, 157, 219;
  --wingu-accent-dark-hover-rgb: 149, 117, 205;
}

html[data-wingu-accent="blue"] {
  --wingu-accent-light-rgb: 21, 101, 192;
  --wingu-accent-light-hover-rgb: 13, 71, 161;
  --wingu-accent-dark-rgb: 144, 202, 249;
  --wingu-accent-dark-hover-rgb: 100, 181, 246;
}

html:not([data-theme="dark"]) {
  --wingu-ui-accent-rgb: var(--wingu-accent-light-rgb);
}

html[data-theme="dark"] {
  --wingu-ui-accent-rgb: var(--wingu-accent-dark-rgb);
}

html[data-color="all"]:not([data-theme="dark"]) {
  --primary-rgb: var(--wingu-accent-light-rgb);
  --primary-rgb-picr: var(--wingu-accent-light-rgb);
  --wingu-accent-hover-rgb: var(--wingu-accent-light-hover-rgb);
  --wingu-on-accent: #ffffff;
}

html[data-color="all"][data-theme="dark"] {
  --primary-rgb: var(--wingu-accent-dark-rgb);
  --primary-rgb-picr: var(--wingu-accent-dark-rgb);
  --wingu-accent-hover-rgb: var(--wingu-accent-dark-hover-rgb);
  --wingu-on-accent: #000000;
}

html[data-color="all"] .btn.btn-primary,
html[data-color="all"] .btn.btn-login,
html[data-color="all"] .page-header .btn-added,
html[data-color="all"] .bg-primary,
html[data-color="all"] .badge.badge-primary,
html[data-color="all"] .dataTables_paginate .pagination li.active a.page-link {
  color: var(--wingu-on-accent) !important;
}

html[data-color="all"] .btn.btn-primary:hover,
html[data-color="all"] .btn.btn-primary:focus,
html[data-color="all"] .btn.btn-primary:active,
html[data-color="all"] .btn.btn-primary.active,
html[data-color="all"] .btn.btn-login:hover,
html[data-color="all"] .btn.btn-login:focus,
html[data-color="all"] .btn.btn-login:active,
html[data-color="all"] .page-header .btn-added:hover,
html[data-color="all"] .page-header .btn-added:focus,
html[data-color="all"] .btn-outline-primary:hover,
html[data-color="all"] .btn-outline-primary:focus,
html[data-color="all"] .btn-outline-primary:active {
  background-color: rgb(var(--wingu-accent-hover-rgb)) !important;
  border-color: rgb(var(--wingu-accent-hover-rgb)) !important;
  color: var(--wingu-on-accent) !important;
}

html[data-color="all"] .btn.btn-login {
  background-color: rgb(var(--primary-rgb-picr)) !important;
  border-color: rgb(var(--primary-rgb-picr)) !important;
}

html[data-theme="dark"][data-color="all"] .form-check-input:checked[type="checkbox"] {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23000' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='m6 10 3 3 6-6'/%3e%3c/svg%3e");
}

html[data-theme="dark"][data-color="all"] .form-check-input:checked[type="radio"] {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='2' fill='%23000'/%3e%3c/svg%3e");
}

html[data-theme="dark"][data-color="all"] .select2-container--default .select2-results__option--highlighted[aria-selected] {
  color: #000000;
}

html[data-color="all"] :where(a, button, input, select, textarea):focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 2px;
  box-shadow: 0 0 0 4px #111827;
}

.appearance-brand-slot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.appearance-brand-slot--full {
  width: 180px;
  height: 56px;
}

.appearance-brand-slot--compact {
  width: 44px;
  height: 44px;
}

.appearance-brand-slot img,
.appearance-auth-brand img,
.appearance-lock-brand img {
  width: 100% !important;
  height: 100% !important;
  max-width: 100%;
  object-fit: contain;
}

.appearance-brand-slot--plate {
  padding: 5px;
  border: 1px solid #d8dee7;
  border-radius: 6px;
  background: #ffffff;
}

.appearance-auth-brand {
  width: 200px;
  max-width: 200px !important;
  min-height: 66px;
}

.appearance-auth-brand > a {
  width: 200px;
  height: 66px;
}

.appearance-auth-brand__dark {
  padding: 5px;
}

html[data-theme="dark"] .login-wrapper .login-content .appearance-auth-brand {
  display: block;
}

html[data-theme="dark"] .appearance-auth-brand__light {
  display: none;
}

html:not([data-theme="dark"]) .appearance-auth-brand__dark {
  display: none !important;
}

.appearance-lock-brand {
  display: flex;
  width: 200px;
  height: 66px;
  margin: 0 auto 3rem;
}

.appearance-mode-menu {
  min-width: 190px;
}

.appearance-mode-picker {
  display: grid;
  gap: 4px;
}

.appearance-mode-picker__option {
  display: grid;
  grid-template-columns: 22px 1fr 18px;
  align-items: center;
  width: 100%;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  color: inherit;
  text-align: left;
}

.appearance-mode-picker__option:hover,
.appearance-mode-picker__option.is-selected {
  border-color: rgb(var(--wingu-ui-accent-rgb));
  background: rgba(var(--wingu-ui-accent-rgb), 0.12);
}

.appearance-mode-picker__check {
  visibility: hidden;
}

.appearance-mode-picker__option.is-selected .appearance-mode-picker__check {
  visibility: visible;
}

.appearance-logo-card {
  padding: 16px;
  border: 1px solid #e6eaed;
  border-radius: 8px;
}

.appearance-logo-preview {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 110px;
  margin-bottom: 16px;
  padding: 16px;
  border-radius: 8px;
}

.appearance-logo-preview--light {
  border: 1px solid #e6eaed;
  background: #ffffff;
}

.appearance-logo-preview--dark {
  background: #111827;
}

.appearance-logo-preview img {
  width: 100%;
  height: 64px;
  object-fit: contain;
}

.appearance-choice-card {
  display: grid;
  grid-template-columns: 22px 1fr 20px;
  align-items: center;
  gap: 12px;
  min-height: 82px;
  padding: 16px;
  border: 2px solid #e6eaed;
  border-radius: 10px;
  cursor: pointer;
}

.appearance-choice-card input,
.appearance-palette input {
  accent-color: rgb(var(--wingu-ui-accent-rgb));
}

.appearance-choice-card small {
  display: block;
  color: #64748b;
}

.appearance-choice-card:has(input:checked),
.appearance-palette:has(input:checked) {
  border-color: rgb(var(--wingu-ui-accent-rgb));
}

.appearance-palette-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
}

.appearance-palette {
  display: grid;
  grid-template-columns: 20px 28px 1fr 18px;
  align-items: center;
  gap: 8px;
  padding: 12px;
  border: 2px solid #e6eaed;
  border-radius: 8px;
  cursor: pointer;
}

.appearance-palette__swatch {
  width: 28px;
  height: 28px;
  border: 1px solid #111827;
  border-radius: 50%;
  background: var(--swatch);
}

html[data-theme="dark"] .appearance-logo-card,
html[data-theme="dark"] .appearance-choice-card,
html[data-theme="dark"] .appearance-palette {
  border-color: #374151;
}

#global-loader {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

#global-loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

#global-loader.htmx-request {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

form.pos-product-card {
  position: relative;
}

.pos-product-card__pending {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 2;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.75);
  pointer-events: auto;
  -webkit-backdrop-filter: blur(1px);
  backdrop-filter: blur(1px);
}

form.pos-product-card.htmx-request .pos-product-card__pending {
  display: flex;
}

form.pos-product-card.htmx-request .product-info {
  opacity: 0.6;
}

html[data-theme=dark] form.pos-product-card .pos-product-card__pending {
  background: rgba(0, 0, 0, 0.45);
  color: #ffffff;
}

#pos-product-grid.pos-product-grid-busy form.pos-product-card:not(.htmx-request) {
  pointer-events: none;
  opacity: 0.6;
}

.pos-product-view-toggle .btn {
  width: 40px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.pos-product-card--list .pos-product-list-row {
  min-height: 74px;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 8px;
  color: inherit;
}

.pos-product-list-row__image {
  width: 56px;
  height: 56px;
  flex: 0 0 56px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 6px;
  background: #F9FAFB;
}

.pos-product-list-row__image img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.pos-product-list-row__body {
  min-width: 0;
  flex: 1 1 auto;
}

.pos-product-list-row__name {
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.25;
}

.pos-products .pos-product-card--list.pos-product-in-cart {
  border-width: 2px;
  border-radius: 10px;
  padding: 1px;
}

.pos-product-card--list .pos-product-card__pending {
  border-radius: 8px;
}

html[data-theme=dark] .pos-product-list-row__image {
  background: #2B2B2B;
}

@media (min-width: 992px) {
  body.pos-embedded {
    overflow-y: auto;
  }
}

.header-metric {
  display: flex;
  align-items: center;
  gap: 10px;
}

@media (max-width: 574.98px) {
  .header-metric {
    width: 100%;
  }
}

.header-metric-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
  flex: 0 0 auto;
}

.header-metric-text {
  min-width: 0;
}

.mpesa-accordion .accordion-button,
.mpesa-accordion .accordion-button.collapsed {
  color: #000000;
}

.quick-cash .quick-cash-btn {
  font-size: 20px;
  font-weight: 700;
  border: 1px solid #E6EAED;
  width: 88px;
  height: 62px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  color: #646B72;
  background: #ffffff;
}

.quick-cash .quick-cash-btn:hover {
  background: #ffffff;
}

.quick-cash .quick-cash-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

@media (max-width: 767.98px) {
  .quick-cash .quick-cash-btn {
    height: 50px;
    font-size: 16px;
  }
}

body.pos-page .pos-mobile-tab-switch,
body.pos-page .pos-mobile-status-bar,
body.pos-page .pos-mobile-cart-lines,
body.pos-page .pos-mobile-order-header,
body.pos-page .pos-mobile-summary,
body.pos-page .pos-order-actions-mobile {
  display: none;
}

body.pos-page .pos-mobile-profile-trigger {
  display: none;
}

body.pos-page .pos-mobile-profile-panel {
  width: min(360px, 100vw);
  border-left: 1px solid #DDE2E6;
  background: #ffffff;
}

body.pos-page .pos-mobile-profile-panel .offcanvas-header {
  align-items: flex-start;
  border-bottom: 1px solid #E6EAED;
  padding: 18px;
}

body.pos-page .pos-mobile-profile-panel .offcanvas-body {
  padding: 18px;
}

body.pos-page .pos-mobile-profile-panel__eyebrow {
  color: #64748B;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.1;
  text-transform: uppercase;
}

body.pos-page .pos-mobile-profile-panel__hero {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}

body.pos-page .pos-mobile-profile-panel__avatar {
  width: 54px;
  height: 54px;
  flex: 0 0 54px;
  border-radius: 50%;
  overflow: hidden;
  background: #F8FAFC;
  border: 1px solid #E6EAED;
}

body.pos-page .pos-mobile-profile-panel__avatar img,
body.pos-page .pos-mobile-profile-trigger__button img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

body.pos-page .pos-mobile-profile-panel__identity {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

body.pos-page .pos-mobile-profile-panel__identity strong {
  color: #111827;
  font-size: 16px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

body.pos-page .pos-mobile-profile-panel__identity span {
  color: #64748B;
  font-size: 12px;
  font-weight: 700;
}

body.pos-page .pos-mobile-profile-panel__meta {
  display: grid;
  gap: 10px;
  margin-bottom: 18px;
}

body.pos-page .pos-mobile-profile-panel__meta-item {
  display: grid;
  gap: 2px;
  padding: 10px 12px;
  border: 1px solid #E6EAED;
  border-radius: 8px;
  background: #F8FAFC;
}

body.pos-page .pos-mobile-profile-panel__meta-item span,
body.pos-page .pos-mobile-profile-panel__meta-item small {
  color: #64748B;
  font-size: 12px;
  line-height: 1.25;
}

body.pos-page .pos-mobile-profile-panel__meta-item strong {
  color: #111827;
  font-size: 14px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

body.pos-page .pos-mobile-profile-panel__actions {
  display: grid;
  gap: 10px;
}

body.pos-page .pos-mobile-profile-panel__action {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #DDE2E6;
  border-radius: 8px;
  padding: 10px 12px;
  background: #ffffff;
  color: #1F2937;
  font-weight: 700;
  line-height: 1.2;
}

body.pos-page .pos-mobile-profile-panel__action i {
  flex: 0 0 auto;
  font-size: 18px;
}

body.pos-page .pos-mobile-profile-panel__action span {
  min-width: 0;
  overflow-wrap: anywhere;
}

body.pos-page .pos-mobile-profile-panel__action--primary {
  background: #0D6EFD;
  border-color: #0D6EFD;
  color: #ffffff;
}

body.pos-page .pos-mobile-profile-panel__action--danger {
  border-color: #FFD6D6;
  color: #D92D20;
}

html[data-theme=dark] body.pos-page .pos-mobile-profile-panel {
  background: #1f1f1f;
  border-left-color: #343a40;
  color: #D8DFEE;
}

html[data-theme=dark] body.pos-page .pos-mobile-profile-panel .offcanvas-header {
  border-bottom-color: #343a40;
}

html[data-theme=dark] body.pos-page .pos-mobile-profile-panel .btn-close {
  filter: invert(1) grayscale(100%) brightness(200%);
}

html[data-theme=dark] body.pos-page .pos-mobile-profile-panel h5,
html[data-theme=dark] body.pos-page .pos-mobile-profile-panel__identity strong,
html[data-theme=dark] body.pos-page .pos-mobile-profile-panel__meta-item strong {
  color: #F8FAFC;
}

html[data-theme=dark] body.pos-page .pos-mobile-profile-panel__avatar,
html[data-theme=dark] body.pos-page .pos-mobile-profile-panel__meta-item,
html[data-theme=dark] body.pos-page .pos-mobile-profile-panel__action {
  background: #2B2B2B;
  border-color: #3A3A3A;
}

html[data-theme=dark] body.pos-page .pos-mobile-profile-panel__action {
  color: #F8FAFC;
}

html[data-theme=dark] body.pos-page .pos-mobile-profile-panel__action--primary {
  background: #0D6EFD;
  border-color: #0D6EFD;
  color: #ffffff;
}

html[data-theme=dark] body.pos-page .pos-mobile-profile-panel__action--danger {
  border-color: #6B2B2B;
  color: #FF8A8A;
}

@media (max-width: 991.96px) {
  body.pos-page .header.pos-header .header-left {
    padding-left: 12px;
    padding-right: 66px;
  }

  body.pos-page .pos-mobile-profile-trigger {
    position: absolute;
    top: 0;
    right: 10px;
    z-index: 20;
    height: 65px;
    display: flex;
    align-items: center;
  }

  body.pos-page .pos-mobile-profile-trigger__button {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 5px;
    border: 1px solid #DDE2E6;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.12);
  }

  body.pos-page .pos-mobile-profile-trigger__button img {
    border-radius: 50%;
  }

  html[data-theme=dark] body.pos-page .pos-mobile-profile-trigger__button {
    background: #2B2B2B;
    border-color: #3A3A3A;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
  }
}

@media (max-width: 767.98px) {
  body.pos-page {
    padding-bottom: calc(92px + env(safe-area-inset-bottom));
  }

  body.pos-page.pos-receipt-only {
    padding-bottom: 0;
  }

  body.pos-page .pos-wrapper {
    row-gap: 12px;
  }

  body.pos-page .pos-mobile-tab-switch {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 8px;
    padding: 8px 12px 10px;
    position: sticky;
    top: 0;
    z-index: 90;
    background: #ffffff;
    border-bottom: 1px solid #E6EAED;
  }

  html[data-theme=dark] body.pos-page .pos-mobile-tab-switch {
    background: #1f1f1f;
    border-bottom-color: #343a40;
  }

  body.pos-page .pos-mobile-tab-switch .btn {
    min-height: 44px;
  }

  body.pos-page.pos-mobile-shell-ready.pos-mobile-tab-products [data-pos-mobile-tab-panel="cart"],
  body.pos-page.pos-mobile-shell-ready.pos-mobile-tab-cart [data-pos-mobile-tab-panel="products"] {
    display: none !important;
  }

  body.pos-page.pos-order-confirmed [data-pos-mobile-tab-panel="products"],
  body.pos-page.pos-order-dispatched [data-pos-mobile-tab-panel="products"] {
    display: none !important;
  }

  body.pos-page [data-pos-order-column].theiaStickySidebar {
    position: static !important;
    top: auto !important;
    left: auto !important;
    width: auto !important;
    min-height: 0 !important;
    transform: none !important;
    padding-left: calc(var(--bs-gutter-x) * .5) !important;
  }

  body.pos-page .pos-categories .d-flex.align-items-center.justify-content-between.flex-wrap.gap-3.mb-4.px-3.pt-3 {
    align-items: stretch !important;
    gap: 10px !important;
    margin-bottom: 10px !important;
  }

  body.pos-page .pos-categories .d-flex.align-items-center.justify-content-between.flex-wrap.gap-3.mb-4.px-3.pt-3 > div:first-child {
    display: none;
  }

  body.pos-page form.pos-search {
    width: 100%;
    flex: 1 1 100%;
  }

  body.pos-page .pos-product-view-toggle {
    flex: 0 0 auto;
  }

  body.pos-page .pos-products {
    padding-bottom: 14px !important;
  }

  body.pos-page .pos-products .row {
    --bs-gutter-x: 0.75rem;
    --bs-gutter-y: 0.75rem;
  }

  body.pos-page form.pos-product-card .product-info {
    min-height: 64px;
    border-radius: 8px !important;
  }

  body.pos-page .pos-product-card--grid .product-info {
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
  }

  body.pos-page .pos-product-card--grid .product-image {
    width: 54px;
    height: 54px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 6px;
    background: #F8FAFC;
  }

  body.pos-page .pos-product-card--grid .product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
  }

  body.pos-page .pos-product-card--grid .product-content {
    min-width: 0;
    text-align: left !important;
  }

  body.pos-page .pos-product-card--grid .pos-product-card__name {
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
    overflow-wrap: anywhere;
    line-height: 1.2;
    max-height: 2.4em;
  }

  body.pos-page .pos-product-card__price {
    display: inline-block;
    line-height: 1.2;
  }

  body.pos-page .pos-product-card--list .pos-product-list-row {
    min-height: 64px;
    padding: 7px 9px;
  }

  body.pos-page .pos-product-card--list .pos-product-list-row__image {
    width: 50px;
    height: 50px;
    flex-basis: 50px;
  }

  body.pos-page .pos-cart-lines-table {
    display: none;
  }

  body.pos-page .pos-mobile-cart-lines {
    display: grid;
    gap: 10px;
  }

  body.pos-page .pos-mobile-cart-line {
    border: 1px solid #E6EAED;
    border-radius: 8px;
    background: #ffffff;
    padding: 10px;
  }

  body.pos-page .pos-mobile-cart-line__main {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
  }

  body.pos-page .pos-mobile-cart-line__image {
    width: 54px;
    height: 54px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 7px;
    background: #F8FAFC;
  }

  body.pos-page .pos-mobile-cart-line__image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
  }

  body.pos-page .pos-mobile-cart-line__body {
    min-width: 0;
  }

  body.pos-page .pos-mobile-cart-line__name {
    color: #111827;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.25;
    overflow-wrap: anywhere;
  }

  body.pos-page .pos-mobile-cart-line__meta {
    margin-top: 2px;
    color: #64748B;
    font-size: 11px;
  }

  body.pos-page .pos-mobile-cart-line__qty {
    min-width: 42px;
    text-align: center;
  }

  body.pos-page .pos-mobile-cart-line__qty span,
  body.pos-page .pos-mobile-cart-line__money span {
    display: block;
    color: #64748B;
    font-size: 11px;
    line-height: 1.1;
  }

  body.pos-page .pos-mobile-cart-line__qty strong,
  body.pos-page .pos-mobile-cart-line__money strong {
    display: block;
    color: #111827;
    font-size: 14px;
    line-height: 1.2;
  }

  body.pos-page .pos-mobile-cart-line__money {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #EEF2F6;
  }

  body.pos-page .pos-mobile-cart-line__money em {
    display: block;
    color: #94A3B8;
    font-size: 11px;
    font-style: normal;
    text-decoration: line-through;
  }

  body.pos-page .pos-mobile-cart-line__actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
  }

  body.pos-page .pos-mobile-cart-line__actions form {
    margin: 0;
  }

  body.pos-page .pos-mobile-cart-line__actions .btn {
    min-height: 38px;
  }

  body.pos-page .pos-mobile-order-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid #E6EAED;
    border-radius: 8px;
    background: #ffffff;
  }

  body.pos-page .order-head {
    display: none !important;
  }

  body.pos-page .pos-mobile-order-header__main {
    min-width: 0;
  }

  body.pos-page .pos-mobile-order-header__main span {
    display: block;
    color: #64748B;
    font-size: 11px;
    line-height: 1.1;
  }

  body.pos-page .pos-mobile-order-header__main strong {
    display: block;
    color: #111827;
    font-size: 15px;
    line-height: 1.2;
    overflow-wrap: anywhere;
  }

  body.pos-page .pos-mobile-order-header__badges {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 4px;
  }

  body.pos-page .pos-mobile-order-header__actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
  }

  body.pos-page .pos-mobile-order-header__actions .btn-icon {
    width: 40px;
    height: 40px;
  }

  body.pos-page .pos-desktop-summary {
    display: none;
  }

  body.pos-page .pos-mobile-summary {
    display: block;
  }

  body.pos-page .pos-mobile-summary__primary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }

  body.pos-page .pos-mobile-summary__primary > div {
    min-width: 0;
    padding: 8px;
    border: 1px solid #E6EAED;
    border-radius: 8px;
    background: #ffffff;
  }

  body.pos-page .pos-mobile-summary span,
  body.pos-page .pos-mobile-summary__details summary {
    color: #64748B;
    font-size: 11px;
  }

  body.pos-page .pos-mobile-summary strong {
    display: block;
    color: #111827;
    font-size: 14px;
    line-height: 1.2;
    overflow-wrap: anywhere;
  }

  body.pos-page .pos-mobile-summary__details {
    margin-top: 8px;
  }

  body.pos-page .pos-mobile-summary__details summary {
    min-height: 34px;
    cursor: pointer;
  }

  body.pos-page .pos-mobile-summary__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 5px 0;
  }

  body.pos-page .pos-mobile-summary__label {
    min-width: 0;
    display: inline-flex;
    align-items: center;
    gap: 6px;
  }

  body.pos-page .pos-mobile-summary__edit {
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    line-height: 1;
  }

  body.pos-page .pos-order-actions-desktop {
    display: none;
  }

  body.pos-page .pos-order-actions-mobile {
    display: grid;
    gap: 8px;
    margin-top: 10px;
  }

  body.pos-page .pos-order-actions-mobile .btn {
    min-height: 42px;
  }

  body.pos-page .pos-order-actions-mobile__more summary {
    min-height: 40px;
    display: flex;
    align-items: center;
    color: #475569;
    cursor: pointer;
  }

  body.pos-page .pos-order-actions-mobile__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  body.pos-page .pos-order-actions-mobile__grid form {
    margin: 0;
  }

  body.pos-page #pos-order-payment {
    display: none;
  }

  body.pos-page #pos-payment-cash .modal-dialog {
    width: 100%;
    max-width: none;
    height: 100dvh;
    min-height: 100vh;
    margin: 0;
    align-items: stretch;
  }

  body.pos-page #pos-payment-cash .modal-content {
    min-height: 100vh;
    height: 100dvh;
    border: 0;
    border-radius: 0;
  }

  body.pos-page #pos-payment-cash .modal-header {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #ffffff;
    border-bottom: 1px solid #E6EAED;
  }

  body.pos-page #pos-payment-cash .modal-body {
    overflow-y: auto;
    padding: 12px 12px calc(18px + env(safe-area-inset-bottom)) !important;
  }

  body.pos-page #pos-payment-cash .bg-light.br-10.p-4 {
    padding: 12px !important;
    border-radius: 8px;
  }

  body.pos-page #pos-payment-cash .display-6 {
    font-size: 26px;
    line-height: 1.15;
  }

  body.pos-page #pos-payment-cash .pos-payment-methods {
    display: flex;
    flex-wrap: nowrap;
    justify-content: flex-start !important;
    overflow-x: auto;
    padding-bottom: 4px;
    margin-left: 0;
    margin-right: 0;
  }

  body.pos-page #pos-payment-cash .pos-payment-methods > [class*="col-"] {
    flex: 0 0 128px;
    width: 128px;
    max-width: 128px;
    padding-left: 0;
    padding-right: 8px;
  }

  body.pos-page #pos-payment-cash .payment-item {
    min-height: 74px;
    padding: 8px;
    border-radius: 8px;
  }

  body.pos-page #pos-payment-cash .payment-item img {
    width: 28px;
    height: 28px;
    object-fit: contain;
  }

  body.pos-page #pos-payment-cash .quick-cash [data-pos-quick-cash-buttons] {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  body.pos-page #pos-payment-cash .quick-cash .quick-cash-btn {
    width: 100%;
  }

  body.pos-page .pos-modal .modal-dialog,
  body.pos-page .modal-default .modal-dialog {
    width: calc(100% - 16px);
    max-width: calc(100% - 16px);
    margin-left: 8px;
    margin-right: 8px;
  }

  body.pos-page #pos-after-sale-frame .modal-dialog,
  body.pos-page #print-receipt .modal-dialog,
  body.pos-page #pos-dispatch .modal-dialog {
    width: 100%;
    max-width: none;
    height: 100dvh;
    margin: 0;
  }

  body.pos-page #pos-after-sale-frame .modal-content,
  body.pos-page #print-receipt .modal-content,
  body.pos-page #pos-dispatch .modal-content {
    min-height: 100vh;
    height: 100dvh;
    border-radius: 0;
  }

  body.pos-page #pos-after-sale-iframe {
    height: calc(100dvh - 58px) !important;
  }

  body.pos-page #pos-receipt-frame {
    height: calc(100dvh - 96px) !important;
  }

  html[data-theme=dark] body.pos-page .pos-mobile-cart-line,
  html[data-theme=dark] body.pos-page .pos-product-card--grid .product-image,
  html[data-theme=dark] body.pos-page .pos-mobile-cart-line__image {
    background: #1f1f1f;
    border-color: #343a40;
  }

  body.pos-page .pos-mobile-status-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 980;
    display: grid;
    grid-template-columns: minmax(126px, 1fr) minmax(82px, auto) minmax(132px, 1.15fr);
    align-items: center;
    gap: 8px;
    padding: 8px 10px calc(8px + env(safe-area-inset-bottom));
    background: #ffffff;
    border-top: 1px solid #DDE2E6;
    box-shadow: 0 -8px 22px rgba(15, 23, 42, 0.14);
  }

  html[data-theme=dark] body.pos-page .pos-mobile-status-bar {
    background: #1f1f1f;
    border-top-color: #343a40;
    box-shadow: 0 -8px 22px rgba(0, 0, 0, 0.35);
  }

  body.pos-page.pos-receipt-only .pos-mobile-status-bar {
    display: none !important;
  }

  body.pos-page .pos-mobile-status-bar__tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
  }

  body.pos-page .pos-mobile-status-bar__tab {
    min-height: 46px;
    border: 1px solid #DDE2E6;
    border-radius: 8px;
    background: #F8FAFC;
    color: #1F2937;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1px;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.1;
    padding: 4px;
  }

  body.pos-page .pos-mobile-status-bar__tab strong {
    font-size: 11px;
    line-height: 1;
  }

  body.pos-page .pos-mobile-status-bar__tab.is-active {
    border-color: #0D6EFD;
    background: #EAF2FF;
    color: #0D6EFD;
  }

  body.pos-page .pos-mobile-status-bar__tab:disabled {
    opacity: 0.45;
  }

  body.pos-page .pos-mobile-status-bar__summary {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 1px;
    line-height: 1.1;
    text-align: center;
  }

  body.pos-page .pos-mobile-status-bar__summary span {
    font-size: 11px;
    color: #64748B;
  }

  body.pos-page .pos-mobile-status-bar__summary strong {
    font-size: 14px;
    color: #111827;
    overflow-wrap: anywhere;
  }

  body.pos-page .pos-mobile-status-bar__actions {
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
  }

  body.pos-page .pos-mobile-status-bar__primary {
    min-height: 46px;
    min-width: 0;
    flex: 1 1 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 6px 8px;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.1;
    white-space: normal;
  }

  body.pos-page .pos-mobile-status-bar__secondary {
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
  }
}

@media (min-width: 768px) {
  body.pos-page .pos-mobile-cart-lines {
    display: none;
  }

  body.pos-page .pos-mobile-order-header,
  body.pos-page .pos-mobile-summary,
  body.pos-page .pos-order-actions-mobile {
    display: none;
  }
}

@media (max-width: 420px) {
  body.pos-page .pos-mobile-status-bar {
    grid-template-columns: minmax(112px, 1fr) minmax(70px, auto) minmax(112px, 1fr);
    gap: 6px;
    padding-left: 8px;
    padding-right: 8px;
  }

  body.pos-page .pos-mobile-status-bar__primary {
    font-size: 12px;
  }
}

@media (max-width: 767.98px) {
  body.pos-page .pos-after-sale-table {
    overflow: visible;
  }

  body.pos-page .pos-after-sale-table table,
  body.pos-page .pos-after-sale-table tbody,
  body.pos-page .pos-after-sale-table tr,
  body.pos-page .pos-after-sale-table td {
    display: block;
    width: 100%;
  }

  body.pos-page .pos-after-sale-table thead {
    display: none;
  }

  body.pos-page .pos-after-sale-table tbody {
    display: grid;
    gap: 10px;
    padding: 10px;
  }

  body.pos-page .pos-after-sale-table tr {
    border: 1px solid #E6EAED;
    border-radius: 8px;
    background: #ffffff;
    padding: 8px 10px;
  }

  body.pos-page .pos-after-sale-table td {
    border: 0 !important;
    padding: 5px 0 !important;
    text-align: left !important;
  }

  body.pos-page .pos-after-sale-table td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 2px;
    color: #64748B;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.1;
  }

  body.pos-page .pos-after-sale-table td[data-label="Item"] {
    color: #111827;
    font-size: 14px;
    line-height: 1.25;
    overflow-wrap: anywhere;
  }

  body.pos-page .pos-after-sale-table input.form-control {
    min-height: 42px;
  }

  body.pos-page .pos-after-sale-actions {
    display: grid !important;
    grid-template-columns: 1fr;
    gap: 8px !important;
    padding-bottom: calc(10px + env(safe-area-inset-bottom));
  }

  body.pos-page .pos-after-sale-actions .btn {
    width: 100%;
    min-height: 44px;
  }

  body.pos-page .filepond--root {
    max-width: 100%;
    margin-bottom: 0;
  }

  body.pos-page .filepond--drop-label {
    min-height: 76px;
  }

  body.pos-page .filepond--item {
    width: calc(100% - 0.5em);
  }
}
