
/* iMack Digitals POS v1.5.6 — smartphone-responsive enhancements; desktop remains unchanged. */
.mobile-topbar,.mobile-bottom-nav,.mobile-cart-float,.mobile-back-products,.camera-scan-button{display:none}
.mobile-more-overlay.hidden,.camera-scan-overlay.hidden{display:none!important}
.mobile-more-overlay{position:fixed;inset:0;background:#09121fc9;z-index:75;display:flex;justify-content:flex-end}
.mobile-more-panel{background:#fff;color:#17202b;width:min(390px,90vw);height:100dvh;overflow:auto;padding:20px 18px 32px;box-shadow:-9px 0 35px #0b0e1635}
.mobile-more-head{display:flex;align-items:center;justify-content:space-between;gap:12px}.mobile-more-head h2{margin:0}
.mobile-more-head button,.camera-scan-head button{border:0;background:#f1f2f6;border-radius:9px;padding:7px 13px;font-size:22px;cursor:pointer}
.mobile-more-links{display:grid;gap:8px;margin:20px 0}
.mobile-more-links button{background:#fafbfc;border:1px solid #e3e6ea;text-align:left;border-radius:10px;padding:13px 14px;color:#152435;font-weight:700;cursor:pointer}
.mobile-more-account{border-top:1px solid #e5e7eb;padding:16px 0;display:flex;justify-content:space-between;gap:10px;align-items:center}
.mobile-more-account span{font-size:12px;color:#6c7683}.mobile-more-account button{border:1px solid #ddd;background:#fff;padding:9px 12px;border-radius:8px}
.mobile-install-button{background:#171e27;color:#fff;border:0;border-radius:10px;padding:13px 15px;width:100%;font-weight:700;cursor:pointer}
.camera-scan-overlay{z-index:95}
.camera-scan-panel{position:relative;background:#101a27;color:white;width:min(520px,96vw);padding:18px;border-radius:16px;text-align:center}
.camera-scan-head{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:13px}
.camera-scan-panel video{display:block;width:100%;max-height:54dvh;background:#050910;border-radius:12px;object-fit:cover;aspect-ratio:4/3}
.camera-scan-reticle{position:absolute;border:2px solid #eccb4b;border-radius:15px;inset:auto 17% 38%;height:80px;pointer-events:none;box-shadow:0 0 0 120vmax #0000}
.camera-scan-panel p{margin:12px 0}.camera-help{font-size:11px;color:#b8c3cd}
@media(max-width:720px){
  html{scroll-padding-top:58px}
  body{overflow-x:hidden;padding-bottom:calc(77px + env(safe-area-inset-bottom));background:#f4f6f9}
  body:has(.auth-screen:not(.hidden)){padding-bottom:0}
  .sidebar{display:none!important}
  .mobile-topbar{display:flex;position:sticky;top:0;z-index:7;align-items:center;justify-content:space-between;gap:10px;background:#141d27;color:white;padding:9px 15px;min-height:54px;box-shadow:0 3px 12px #0001}
  body:has(.auth-screen:not(.hidden)) .mobile-topbar,body:has(.auth-screen:not(.hidden)) .mobile-bottom-nav,body:has(.auth-screen:not(.hidden)) .mobile-cart-float{display:none!important}
  .mobile-brand{display:flex;gap:10px;align-items:center;font-size:14px}
  .mobile-brand-mark{display:grid;place-items:center;background:#d4a91d;border-radius:9px;color:#15202b;font-size:14px;font-weight:900;width:33px;height:33px}
  .mobile-live-dot{font-size:11px;color:#c7d3e0;white-space:nowrap}.mobile-live-dot span{color:#56d7a4}
  main{padding:13px 11px 18px!important;margin:0!important;max-width:none!important}
  main>header{margin-bottom:12px;gap:8px}
  main>header .eyebrow{display:none}main>header h1{font-size:20px;margin:2px 0}
  .panel{padding:14px;border-radius:12px;margin-bottom:12px}
  .panelhead{align-items:flex-start;gap:9px;flex-wrap:wrap;margin-bottom:10px}
  .panelhead .sub{font-size:11px}
  .panelhead h2{font-size:16px}
  .stats{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.stat{padding:12px}.stat b{font-size:18px}
  .findrow{gap:6px}.findrow input,.panel input,.panel select{font-size:16px;min-height:44px}
  .mobile-bottom-nav{display:grid;position:fixed;bottom:0;left:0;right:0;z-index:45;grid-template-columns:repeat(4,1fr);background:#fff;border-top:1px solid #dfe3e7;padding:7px 5px calc(7px + env(safe-area-inset-bottom));box-shadow:0 -3px 20px #14202a12}
  .mobile-nav-item{display:flex;align-items:center;flex-direction:column;gap:2px;border:0;background:transparent;color:#596776;padding:6px 2px 4px;font-size:10px;font-weight:700;min-height:43px;cursor:pointer}
  .mobile-nav-item.active{color:#735609}.mobile-nav-icon{font-size:23px;line-height:1}
  .mobile-cart-float{display:none;position:fixed;left:12px;right:12px;bottom:calc(72px + env(safe-area-inset-bottom));z-index:43;padding:13px 16px;border:0;border-radius:13px;background:#151e29;color:white;box-shadow:0 7px 25px #12202e49;align-items:center;justify-content:space-between;gap:8px;font-size:13px;cursor:pointer}
  .mobile-cart-float b{font-weight:600;font-size:11px;opacity:.7;padding-left:8px}.mobile-cart-float strong{color:#f8da73}
  #checkout.active:not(.mobile-cart-open)~*{} /* qualifier to avoid changing desktop */
  #checkout.active:not(.mobile-cart-open) .productchoices{max-height:none;overflow:visible}
  #checkout .cols{display:block!important}
  #checkout .cols>div:first-child{display:block!important}
  #checkout .cart-primary{position:static!important;top:auto!important}
  #checkout.active:not(.mobile-cart-open) .cart-primary{display:none}
  #checkout.active.mobile-cart-open .cols>div:first-child>.panel:first-child{display:none}
  #checkout.active.mobile-cart-open .cart-primary{display:block}
  #checkout.active.mobile-cart-open .mobile-back-products{display:inline-flex;margin-bottom:10px;font-size:12px}
  .productchoice{min-height:71px;padding:12px;gap:9px;cursor:pointer}
  .productchoice b{font-size:13px}.productchoice small{font-size:11px}
  .choice-info{text-align:right;min-width:100px}
  .scan-to-cart.compact-scan{display:block;padding:9px}
  .scan-to-cart.compact-scan label{display:flex;justify-content:space-between;align-items:center;gap:6px;margin-bottom:6px}
  .scan-to-cart.compact-scan input{min-width:0;height:42px;font-size:16px}
  .scan-to-cart.compact-scan button{min-height:41px}
  .camera-scan-button{display:inline-flex;white-space:nowrap;align-items:center;justify-content:center}
  .product-search-bar{padding:10px}
  .product-search-bar input{min-height:44px}
  .cart-quick{padding:12px;margin-top:12px}
  .cart-quick strong{font-size:20px}
  .shift-panel.compact{padding:10px 12px}
  .shift-panel.compact .shift-row{display:block}
  .shift-panel.compact .shift-meta{min-width:0}
  .shift-panel.compact .shift-status-line{gap:5px}
  .shift-panel.compact .shift-actions{display:flex;flex-wrap:nowrap;overflow:auto;margin-top:8px;padding-bottom:4px;scrollbar-width:thin}
  .shift-panel.compact .shift-actions button{flex:0 0 auto;min-height:41px;white-space:nowrap;width:auto!important}
  .shift-panel.compact .drawer-available{padding:5px 8px;font-size:11px}
  .overlay{padding:0!important;align-items:stretch!important;z-index:60}
  .overlay>.modal{border-radius:16px 16px 0 0!important;width:100%!important;max-width:none!important;max-height:100dvh!important;min-height:80dvh;overflow-y:auto;padding:22px 15px calc(24px + env(safe-area-inset-bottom))!important;margin-top:auto!important}
  #modalBackdrop .modal.receipt-modal{min-height:75dvh}
  #bulkSubModal{z-index:70}
  #bulkSubModal .modal{min-height:65dvh}
  #checkoutOverlay .checkout-dialog{min-height:85dvh}
  .modal label input,.modal label select,.modal label textarea{font-size:16px!important;min-height:44px}
  .modal .two{grid-template-columns:1fr}
  .pick-serial-list{grid-template-columns:repeat(2,minmax(0,1fr));max-height:40dvh}
  .pick-serial-list label{font-size:12px;min-height:40px}
  .pick-footer{position:sticky;bottom:-22px;background:white;padding:14px 0 22px;flex-wrap:wrap;z-index:2}
  .pick-footer button{width:100%}
  .checkout-dialog .summary h2{font-size:20px}
  .tablewrap{overflow:auto;max-width:100vw;-webkit-overflow-scrolling:touch}
  #inventory .inventory-head-actions{display:flex;gap:6px;flex-wrap:wrap}
  #inventory .inventory-head-actions button{font-size:11px}
  .inventory-filters{display:grid;grid-template-columns:1fr 1fr;gap:8px}
  .inventory-filters label{min-width:0}
  .inventory-filters select{width:100%;font-size:12px}

  /* Responsive inventory and transaction records as touch-friendly stacked cards. */
  .mobile-card-table,.mobile-card-table tbody{display:block;width:100%}
  .mobile-card-table thead{display:none}
  .mobile-card-table tbody tr{display:block;background:#fff;border:1px solid #e1e5ea;border-radius:11px;padding:8px 12px;margin-bottom:10px;box-shadow:0 1px 4px #1420290a}
  .mobile-card-table tbody td{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;white-space:normal;overflow-wrap:anywhere;font-size:12px;padding:9px 2px;min-height:30px}
  .mobile-card-table tbody td::before{content:attr(data-label);color:#617184;font-size:10px;flex:0 0 35%;font-weight:750;letter-spacing:.02em;text-transform:uppercase}
  .mobile-card-table tbody td:last-child{border-bottom:0}
  .mobile-card-table tbody td button{margin:2px;white-space:normal;min-height:36px}

  .modal .receipt-preview-scroller{overflow-x:auto}
  .camera-scan-overlay{z-index:95;align-items:center!important;padding:12px!important}
  .camera-scan-overlay .camera-scan-panel{border-radius:16px}
  .auth-screen{z-index:99}
}
@media(min-width:721px){.mobile-topbar,.mobile-bottom-nav,.mobile-cart-float,.mobile-back-products,.camera-scan-button{display:none!important}}
@media print{.mobile-topbar,.mobile-bottom-nav,.mobile-cart-float,.mobile-more-overlay,.camera-scan-overlay{display:none!important}}
