:root{--bg:#eef3f9;--card:#fff;--ink:#0f172a;--muted:#64748b;--line:#dbe3ef;--blue:#2563eb;--dark:#0f172a;--red:#dc2626}
*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink);font-family:Inter,system-ui,-apple-system,Segoe UI,Arial,sans-serif}.hidden{display:none!important}
button,input{font:inherit}button{border:0;border-radius:14px;padding:11px 14px;font-weight:850;background:#e7edf6;color:var(--ink);cursor:pointer}.primary{background:var(--blue);color:#fff}.danger{background:var(--red);color:#fff}.full{width:100%}
input{width:100%;border:1px solid var(--line);border-radius:14px;padding:12px;background:#fff;outline:none}input:focus{border-color:var(--blue);box-shadow:0 0 0 3px #2563eb22}
#toast{position:fixed;top:18px;left:50%;transform:translateX(-50%);z-index:3000;background:#111827;color:#fff;padding:12px 18px;border-radius:999px;display:none}
.login{min-height:100vh;display:grid;place-items:center;padding:20px}.loginCard{width:min(390px,100%);background:#fff;border-radius:28px;padding:28px;box-shadow:0 20px 60px #0f172a22}.brand{width:64px;height:64px;border-radius:20px;background:linear-gradient(135deg,#0f172a,#2563eb);color:white;display:grid;place-items:center;font-weight:950;margin-bottom:14px}.login h1{margin:0 0 16px}
.app{display:grid;grid-template-columns:260px 1fr;min-height:100vh}.sidebar{position:sticky;top:0;height:100vh;background:#0f172a;color:#fff;padding:18px;display:flex;flex-direction:column;gap:8px}.sideBrand{display:flex;gap:12px;align-items:center;padding-bottom:18px;border-bottom:1px solid #ffffff22;margin-bottom:14px}.brandIcon{width:42px;height:42px;background:#2563eb;border-radius:14px;display:grid;place-items:center;font-weight:950}.sideBrand span{display:block;color:#94a3b8;font-size:12px}.nav{text-align:left;background:transparent;color:#cbd5e1}.nav.active,.nav:hover{background:#ffffff18;color:#fff}.sideFooter{margin-top:auto;display:flex;justify-content:space-between;align-items:center;border-top:1px solid #ffffff22;padding-top:14px}.sideFooter span{font-size:12px;color:#cbd5e1}
.content{min-width:0}.topbar{position:sticky;top:0;z-index:20;background:#eef3f9ee;backdrop-filter:blur(12px);border-bottom:1px solid var(--line);padding:18px 22px;display:flex;justify-content:space-between;gap:12px;align-items:center}.topbar h2{margin:0}.topbar p{margin:4px 0 0;color:var(--muted)}.topActions{display:flex;gap:8px}
.panel{padding:20px}.card{background:#fff;border:1px solid var(--line);border-radius:26px;padding:18px;box-shadow:0 10px 30px #0f172a0b}.toolbar{display:flex;justify-content:space-between;align-items:flex-start;gap:10px;margin-bottom:14px}.toolbar h3{margin:0}.toolbar p{margin:4px 0 0;color:var(--muted)}
.searchBar{display:grid;grid-template-columns:1fr auto;gap:10px}.bulkBar{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:12px 0}.bulkBar span{margin-left:auto;color:var(--muted);font-size:13px}.tableWrap{overflow:auto;border:1px solid var(--line);border-radius:20px}table{width:100%;border-collapse:separate;border-spacing:0;min-width:980px}th{background:#f8fafc;text-align:left;font-size:12px;text-transform:uppercase;color:#334155;letter-spacing:.04em}th,td{padding:10px 12px;border-bottom:1px solid var(--line);vertical-align:middle}tr:hover td{background:#f8fafc}.filterRow th{padding:7px;background:#fff}.filterInput{padding:7px;border-radius:9px;font-size:12px}.productName{font-weight:900}.smallMeta{display:block;color:var(--muted);font-size:12px}.priceCell{font-weight:950;white-space:nowrap}.actionBtns{display:flex;gap:6px}.actionBtns button{padding:8px 10px}.pager{display:flex;justify-content:center;gap:10px;margin-top:12px}.buttonRow{display:flex;gap:8px;flex-wrap:wrap;margin:12px 0}
#reader{width:100%;max-width:440px;margin:12px auto;border-radius:22px;overflow:hidden}.manualSku{display:grid;grid-template-columns:1fr auto;gap:8px}.basketList{display:grid;grid-template-columns:repeat(2,1fr);gap:10px}.basketItem{border:1px solid var(--line);border-radius:18px;padding:12px;background:#fff}.editGrid{display:grid;grid-template-columns:1fr 2fr .8fr;gap:8px;margin-top:10px}.settingsGrid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.settingsGrid label{font-weight:800;font-size:12px;color:#334155}.toggleGrid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:12px 0}.toggleGrid input{width:auto;margin-right:8px}#labelPreview{min-height:175px;display:grid;place-items:center;background:#f8fafc;border:1px dashed #cbd5e1;border-radius:20px}.labelMock{width:255px;background:#fff;border:1px solid #111;padding:10px;text-align:center}.labelMock .p1{font-weight:900;font-size:15px}.labelMock .p2{font-size:14px}.labelMock .price{font-size:22px;font-weight:900;margin:8px 0}.fakeBarcode{height:34px;background:repeating-linear-gradient(90deg,#111 0 2px,#fff 2px 4px,#111 4px 5px,#fff 5px 8px);margin:8px 0}.barcodeText{font-size:11px}
.modal{position:fixed;inset:0;background:#0f172a88;display:grid;place-items:center;z-index:2500;padding:20px}.modalBox{width:min(380px,100%);background:#fff;border-radius:24px;padding:22px;box-shadow:0 30px 80px #0005}.modalActions{display:flex;justify-content:flex-end;gap:8px;margin-top:14px}
.mobileBar{display:none}
@media(max-width:900px){.app{grid-template-columns:1fr}.sidebar{display:none}.topbar{padding:14px}.topActions button:first-child{display:none}.panel{padding:10px}.card{padding:12px;border-radius:18px}.searchBar{grid-template-columns:1fr}.bulkBar span{width:100%;margin-left:0}.basketList,.settingsGrid,.toggleGrid,.editGrid{grid-template-columns:1fr}.tableWrap{border-radius:16px}table{min-width:860px}th,td{padding:9px;font-size:13px}.filterInput{padding:6px;font-size:11px}.mobileBar{position:fixed;bottom:0;left:0;right:0;z-index:1000;background:#fff;border-top:1px solid var(--line);display:grid;grid-template-columns:repeat(4,1fr);gap:6px;padding:8px}.mobileBar button{padding:10px}.content{padding-bottom:70px}}


.loginFooter{margin-top:18px;border-top:1px solid var(--line);padding-top:14px;color:var(--muted);font-size:12px;line-height:1.35}
.loginFooter p{margin:4px 0}
.legalLinks{display:flex;gap:10px;flex-wrap:wrap;margin-top:10px}
.legalLinks a,.navLink{color:inherit;text-decoration:none}
.legalLinks a{color:#2563eb;font-weight:800}
.hint{color:var(--muted);margin:6px 0 12px}
.cameraBox{display:grid;grid-template-columns:1fr auto;gap:8px;margin:10px 0}
.cameraBox select{width:100%;border:1px solid var(--line);border-radius:14px;padding:12px;background:#fff}
.cameraMsg{background:#f8fafc;border:1px solid var(--line);border-radius:14px;padding:10px;color:var(--muted);font-size:13px;margin:8px 0}
.cameraHelp{background:#f8fafc;border:1px solid var(--line);border-radius:14px;padding:10px;margin-top:10px;color:#334155}
.cameraHelp summary{font-weight:900;cursor:pointer}
.cameraHelp ol{margin:10px 0 0;padding-left:20px;line-height:1.7}
.appFooter{display:flex;gap:12px;flex-wrap:wrap;justify-content:center;color:var(--muted);font-size:12px;padding:18px 12px 90px}
.sideFooter{flex-wrap:wrap}
.sideFooter small{width:100%;color:#94a3b8;font-size:11px}
.pageShell{max-width:980px;margin:0 auto;padding:22px}
.pageCard{background:#fff;border:1px solid var(--line);border-radius:26px;padding:24px;box-shadow:0 10px 30px #0f172a0b}
.pageCard h1{margin-top:0}
.pageCard h2{margin-top:26px}
.pageCard p,.pageCard li{line-height:1.7;color:#334155}
.backLink{display:inline-block;margin-bottom:14px;color:#2563eb;font-weight:900;text-decoration:none}
.stepList{counter-reset:step;list-style:none;padding:0}
.stepList li{counter-increment:step;background:#f8fafc;border:1px solid var(--line);border-radius:16px;padding:14px 14px 14px 54px;margin:10px 0;position:relative}
.stepList li:before{content:counter(step);position:absolute;left:14px;top:14px;width:28px;height:28px;border-radius:50%;background:#2563eb;color:white;display:grid;place-items:center;font-weight:900}
@media(max-width:900px){
  .cameraBox{grid-template-columns:1fr}
  .appFooter{padding-bottom:82px}
}


/* Professional RMPT login */
.login{
  min-height:100vh;
  display:grid;
  place-items:center;
  padding:24px;
  background:
    radial-gradient(circle at top left, rgba(37,99,235,.18), transparent 34%),
    radial-gradient(circle at bottom right, rgba(20,184,166,.16), transparent 32%),
    linear-gradient(135deg,#eef3f9,#ffffff);
}
.loginLayout{
  width:min(1080px,100%);
  display:grid;
  grid-template-columns:1.1fr .9fr;
  gap:22px;
  align-items:stretch;
}
.loginHero{
  background:linear-gradient(135deg,#0f172a,#1e3a8a);
  color:white;
  border-radius:34px;
  padding:36px;
  box-shadow:0 30px 80px rgba(15,23,42,.22);
  display:flex;
  flex-direction:column;
  justify-content:center;
  min-height:520px;
  overflow:hidden;
  position:relative;
}
.loginHero:after{
  content:"";
  position:absolute;
  width:280px;
  height:280px;
  border-radius:50%;
  background:rgba(255,255,255,.08);
  right:-80px;
  bottom:-90px;
}
.companyLogo{
  width:min(330px,100%);
  background:white;
  padding:18px;
  border-radius:28px;
  box-shadow:0 22px 60px rgba(0,0,0,.25);
  margin-bottom:28px;
  position:relative;
  z-index:1;
}
.loginHero h1{
  margin:0;
  font-size:44px;
  line-height:1;
  letter-spacing:-.04em;
  position:relative;
  z-index:1;
}
.loginHero p{
  color:#dbeafe;
  font-size:17px;
  line-height:1.6;
  max-width:520px;
  position:relative;
  z-index:1;
}
.loginHighlights{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  margin-top:18px;
  position:relative;
  z-index:1;
}
.loginHighlights span{
  background:rgba(255,255,255,.12);
  border:1px solid rgba(255,255,255,.18);
  color:white;
  border-radius:999px;
  padding:9px 12px;
  font-weight:850;
  font-size:13px;
}
.loginCard{
  background:rgba(255,255,255,.92);
  border:1px solid rgba(219,227,239,.95);
  border-radius:34px;
  padding:34px;
  box-shadow:0 30px 80px rgba(15,23,42,.14);
  display:flex;
  flex-direction:column;
  justify-content:center;
}
.loginBadge{
  width:max-content;
  background:#eff6ff;
  color:#1d4ed8;
  border:1px solid #bfdbfe;
  border-radius:999px;
  padding:8px 12px;
  font-weight:900;
  font-size:12px;
  margin-bottom:18px;
  text-transform:uppercase;
  letter-spacing:.06em;
}
.loginCard h2{
  margin:0;
  font-size:32px;
  letter-spacing:-.03em;
}
.loginSub{
  color:var(--muted);
  margin:8px 0 18px;
}
.loginCard input{
  font-size:18px;
  padding:15px;
  border-radius:18px;
}
.loginCard .primary{
  margin-top:10px;
  padding:15px;
  border-radius:18px;
  font-size:16px;
}
.loginLinks{
  display:flex;
  justify-content:center;
  gap:16px;
  margin-top:18px;
}
.loginLinks a{
  color:#2563eb;
  text-decoration:none;
  font-weight:850;
  font-size:13px;
}
#loginMsg{
  margin-top:10px;
  color:#dc2626;
  min-height:18px;
}
.appFooter{display:none!important}
@media(max-width:900px){
  .login{padding:16px}
  .loginLayout{grid-template-columns:1fr}
  .loginHero{min-height:auto;padding:26px;border-radius:28px}
  .companyLogo{width:min(260px,100%);margin-bottom:22px}
  .loginHero h1{font-size:34px}
  .loginHero p{font-size:15px}
  .loginCard{padding:26px;border-radius:28px}
  .loginCard h2{font-size:26px}
}

.simpleCameraHead{
  display:flex;
  align-items:center;
  gap:12px;
  background:#f8fafc;
  border:1px solid var(--line);
  border-radius:18px;
  padding:12px;
  margin:10px 0;
}
.cameraIcon{
  width:52px;
  height:52px;
  border-radius:18px;
  display:grid;
  place-items:center;
  background:#2563eb;
  color:#fff;
  font-size:26px;
  flex:0 0 auto;
}
.simpleCameraHead .cameraMsg{
  border:0;
  background:transparent;
  padding:4px 0 0;
  margin:0;
}

#reader video{
  object-fit:cover!important;
}
#reader{
  min-height:260px;
  background:#000;
}
.simpleCameraHead{
  border-color:#bfdbfe!important;
  background:#eff6ff!important;
}
@media(max-width:900px){
  #reader{min-height:300px}
}


/* Android/iPhone camera friendly scanner */
#reader{
  width:100%;
  max-width:520px;
  min-height:240px;
  margin:12px auto;
  border-radius:22px;
  overflow:hidden;
  background:#000;
}
#reader video{
  width:100%!important;
  height:auto!important;
}
.iconBtn{
  min-width:54px;
  font-size:18px;
}
@media(max-width:900px){
  #reader{
    min-height:260px;
    max-width:100%;
  }
  .simpleCameraHead{
    align-items:flex-start;
  }
}


/* Clean professional login - final */
.login{
  min-height:100vh!important;
  display:grid!important;
  place-items:center!important;
  padding:20px!important;
  background:
    radial-gradient(circle at top left, rgba(37,99,235,.16), transparent 32%),
    linear-gradient(135deg,#eef3f9,#ffffff)!important;
}
.cleanLoginCard{
  width:min(420px,100%)!important;
  padding:34px!important;
  border-radius:30px!important;
  background:rgba(255,255,255,.96)!important;
  border:1px solid rgba(219,227,239,.95)!important;
  box-shadow:0 28px 80px rgba(15,23,42,.16)!important;
  text-align:center!important;
}
.loginLogo{
  width:min(260px,100%)!important;
  display:block!important;
  margin:0 auto 22px!important;
  border-radius:22px!important;
}
.cleanLoginCard h1{
  margin:0 0 22px!important;
  font-size:28px!important;
  letter-spacing:-.03em!important;
  color:#0f172a!important;
}
.cleanLoginCard input{
  text-align:center!important;
  font-size:18px!important;
  padding:16px!important;
  border-radius:18px!important;
}
.cleanLoginCard button{
  margin-top:12px!important;
  padding:15px!important;
  border-radius:18px!important;
}
.cleanLoginCard #loginMsg{
  display:block!important;
  margin-top:12px!important;
  min-height:18px!important;
}
.loginLayout,.loginHero,.loginHighlights,.loginBadge,.loginSub,.loginLinks,.loginFooter{
  display:none!important;
}
.emptyPreview{
  color:#64748b;
  font-weight:850;
  text-align:center;
  padding:24px;
}


/* Final mobile-friendly login fit */
.cleanLoginCard{
  max-width:420px!important;
  width:100%!important;
  padding:28px!important;
}
.loginLogo{
  width:100%!important;
  max-width:280px!important;
  max-height:120px!important;
  object-fit:contain!important;
  border-radius:18px!important;
  margin:0 auto 18px!important;
  display:block!important;
}
.cleanLoginCard h1{
  font-size:26px!important;
  margin-bottom:18px!important;
}
@media(max-width:480px){
  .login{padding:14px!important}
  .cleanLoginCard{
    padding:22px!important;
    border-radius:24px!important;
  }
  .loginLogo{
    max-width:230px!important;
    max-height:95px!important;
  }
  .cleanLoginCard h1{
    font-size:23px!important;
  }
}

/* Final camera permission UX */
.cameraStartCard{
  background:linear-gradient(135deg,#ffffff,#eff6ff);
  border:1px solid #bfdbfe;
  border-radius:24px;
  padding:18px;
  text-align:center;
  margin:10px 0 12px;
  box-shadow:0 10px 28px rgba(37,99,235,.10);
}
.cameraStartCard h4{
  margin:8px 0 5px;
  font-size:20px;
}
.cameraStartCard p{
  color:#334155;
  margin:0 0 12px;
}
.cameraStartCard small{
  display:block;
  color:#64748b;
  margin-top:10px;
}
.cameraIconBig{
  width:68px;
  height:68px;
  display:grid;
  place-items:center;
  border-radius:24px;
  background:#2563eb;
  color:#fff;
  font-size:34px;
  margin:0 auto;
}
#reader{
  min-height:240px;
}
@media(max-width:900px){
  #reader{min-height:250px}
}


.scannerInputBox{
  background:#f8fafc;
  border:1px solid var(--line);
  border-radius:18px;
  padding:12px;
  margin-top:12px;
}
.scannerInputBox label{
  display:block;
  font-size:12px;
  font-weight:900;
  color:#334155;
  margin-bottom:6px;
  text-transform:uppercase;
  letter-spacing:.04em;
}
.scannerInputBox small{
  display:block;
  color:#64748b;
  margin-top:7px;
  line-height:1.4;
}
.scannerInputBox input{
  font-size:17px;
}


/* ===== FINAL PERFECT CLEAN LOGIN OVERRIDE ===== */
body:has(#login:not(.hidden)) {
  overflow: hidden;
}

#login.login {
  position: fixed !important;
  inset: 0 !important;
  min-height: 100dvh !important;
  width: 100vw !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 18px !important;
  margin: 0 !important;
  background:
    radial-gradient(circle at 20% 15%, rgba(37,99,235,.13), transparent 34%),
    linear-gradient(135deg, #eef3f9 0%, #ffffff 100%) !important;
  z-index: 5000 !important;
}

#login.hidden {
  display: none !important;
}

#login .cleanLoginCard {
  width: min(380px, 100%) !important;
  max-width: 380px !important;
  min-height: auto !important;
  margin: 0 auto !important;
  padding: 26px !important;
  border-radius: 26px !important;
  background: #ffffff !important;
  border: 1px solid #dbe3ef !important;
  box-shadow: 0 24px 70px rgba(15,23,42,.16) !important;
  display: block !important;
  text-align: center !important;
}

#login .loginLogo {
  display: block !important;
  width: 100% !important;
  max-width: 240px !important;
  max-height: 100px !important;
  object-fit: contain !important;
  margin: 0 auto 22px auto !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  background: transparent !important;
}

#login #accessCode {
  width: 100% !important;
  display: block !important;
  text-align: center !important;
  font-size: 18px !important;
  font-weight: 700 !important;
  padding: 15px 16px !important;
  border-radius: 16px !important;
  border: 1px solid #cbd5e1 !important;
  background: #ffffff !important;
  margin: 0 0 12px 0 !important;
}

#login button {
  width: 100% !important;
  display: block !important;
  padding: 15px 16px !important;
  border-radius: 16px !important;
  margin: 0 !important;
  font-size: 16px !important;
  font-weight: 900 !important;
}

#login #loginMsg {
  display: block !important;
  min-height: 18px !important;
  margin-top: 10px !important;
  color: #dc2626 !important;
  font-size: 13px !important;
}

/* Kill all previous demo/marketing login elements permanently */
#login h1,
#login h2,
#login p,
#login .loginHero,
#login .loginLayout,
#login .loginHighlights,
#login .loginBadge,
#login .loginSub,
#login .loginLinks,
#login .loginFooter,
#login .brand,
#login .brandMark,
#login .logoBox {
  display: none !important;
}

@media (max-width: 480px) {
  #login.login {
    padding: 14px !important;
    align-items: center !important;
  }

  #login .cleanLoginCard {
    width: 100% !important;
    max-width: 350px !important;
    padding: 22px !important;
    border-radius: 24px !important;
  }

  #login .loginLogo {
    max-width: 210px !important;
    max-height: 82px !important;
    margin-bottom: 18px !important;
  }

  #login #accessCode {
    font-size: 17px !important;
    padding: 14px !important;
  }
}
/* ===== END FINAL PERFECT CLEAN LOGIN OVERRIDE ===== */


.offerList{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:12px}
.offerItem{border:1px solid var(--line);border-radius:18px;padding:14px;background:#fff}
.offerHead{display:flex;justify-content:space-between;gap:10px;align-items:flex-start;margin-bottom:10px}
.offerHead b{display:block;line-height:1.3}
.offerHead span{color:var(--muted);font-size:12px;font-weight:800}
.offerGrid{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.offerGrid label{font-size:12px;font-weight:800;color:#334155}
.offerGrid input{margin-top:6px}
@media(max-width:900px){.offerList{grid-template-columns:1fr}}


/* Final login isolation: login never appears on dashboard */
body.logged-in #login,
body.logged-in #login.login,
#login.hidden {
  display:none!important;
  visibility:hidden!important;
  pointer-events:none!important;
}
body.logged-in{
  overflow:auto!important;
}
body:not(.logged-in) #app{
  display:none!important;
}

/* Simple scan page */
.scanCard{
  max-width:720px;
  margin:0 auto;
}
.scanSearchRow{
  display:grid;
  grid-template-columns:1fr 56px;
  gap:10px;
  align-items:center;
}
.scanSearchRow input{
  height:54px;
  font-size:18px;
  border-radius:18px;
}
.cameraCircleBtn{
  width:56px;
  height:54px;
  border-radius:18px;
  display:grid;
  place-items:center;
  font-size:23px;
  padding:0;
}
.cameraMsg.compact{
  margin:10px 0;
  padding:9px 12px;
  border-radius:14px;
  background:#f8fafc;
  border:1px solid var(--line);
  color:#64748b;
  font-size:13px;
}
.scanResults{
  display:grid;
  gap:8px;
  margin:10px 0;
}
.scanResultItem{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:10px;
  background:#fff;
  border:1px solid var(--line);
  border-radius:16px;
  padding:10px;
}
.scanResultItem b{
  display:block;
  line-height:1.3;
}
.scanResultItem span{
  display:block;
  color:#64748b;
  font-size:12px;
  margin-top:2px;
}
.scanResultItem button{
  flex:0 0 auto;
  padding:9px 12px;
}
.scanActions{
  justify-content:center;
}
@media(max-width:700px){
  .scanSearchRow{
    grid-template-columns:1fr 52px;
  }
  .scanSearchRow input{
    height:52px;
    font-size:16px;
  }
  .cameraCircleBtn{
    height:52px;
    width:52px;
  }
}


.catPreview{
  font-size:10px;
  color:#64748b;
  margin-bottom:4px;
  font-weight:800;
}


#reader.hidden{
  display:none!important;
}
#reader{
  background:#000;
  min-height:260px;
}
.scanSearchRow input:focus{
  border-color:#2563eb;
  box-shadow:0 0 0 3px rgba(37,99,235,.18);
}
.cameraCircleBtn:active{
  transform:scale(.96);
}


/* Stable scan page */
#reader.hidden{display:none!important}
#reader{background:#000;min-height:260px;border-radius:18px;overflow:hidden}
.scanSearchRow{display:grid;grid-template-columns:1fr 56px;gap:10px;align-items:center}
.scanSearchRow input{height:54px;font-size:18px;border-radius:18px}
.cameraCircleBtn{width:56px;height:54px;border-radius:18px;display:grid;place-items:center;font-size:23px;padding:0}
.cameraMsg.compact{margin:10px 0;padding:9px 12px;border-radius:14px;background:#f8fafc;border:1px solid var(--line);color:#64748b;font-size:13px}
.scanResults{display:grid;gap:8px;margin:10px 0}
.scanResultItem{display:flex;justify-content:space-between;align-items:center;gap:10px;background:#fff;border:1px solid var(--line);border-radius:16px;padding:10px}
.scanResultItem b{display:block;line-height:1.3}
.scanResultItem span{display:block;color:#64748b;font-size:12px;margin-top:2px}
.scanResultItem button{flex:0 0 auto;padding:9px 12px}
@media(max-width:700px){.scanSearchRow{grid-template-columns:1fr 52px}.scanSearchRow input{height:52px;font-size:16px}.cameraCircleBtn{height:52px;width:52px}}

.settingsGrid select{width:100%;border:1px solid var(--line);border-radius:14px;padding:12px;background:#fff;outline:none;margin-top:7px}
.settingsGrid input[type="color"]{min-height:45px;padding:5px}
.font-clean_sans{font-family:Arial,Helvetica,sans-serif}
.font-premium_sans{font-family:Inter,Arial,Helvetica,sans-serif;letter-spacing:.01em}
.font-classic_serif{font-family:Georgia,"Times New Roman",serif}
.font-bold_retail{font-family:Arial Black,Arial,sans-serif}
.font-compact_tag{font-family:Arial Narrow,Arial,sans-serif}
.font-courier_tag{font-family:"Courier New",monospace}
.font-modern_light{font-family:Arial,Helvetica,sans-serif;font-weight:400}
.font-strong_title{font-family:Impact,Arial Black,sans-serif;letter-spacing:.02em}
.font-soft_rounded{font-family:Trebuchet MS,Arial,sans-serif}
.font-elegant_serif{font-family:"Times New Roman",Georgia,serif}
.font-receipt_style{font-family:"Courier New",monospace}
.font-high_contrast{font-family:Arial Black,Arial,sans-serif}


#reader video{
  object-fit:cover!important;
}
#reader{
  min-height:280px;
}
@media(max-width:700px){
  #reader{min-height:300px}
}

.toolbarBtns{display:flex;gap:8px;flex-wrap:wrap}
#cacheStatus{font-weight:900;color:#2563eb}

.syncHint{
  color:#64748b;
  font-size:12px;
  margin:8px 0 0;
}

.syncHint{
  font-weight:700;
}


/* Mobile left drawer menu */
.hamburgerBtn{
  display:none;
  width:44px;
  height:44px;
  border-radius:14px;
  padding:0;
  font-size:22px;
  flex:0 0 auto;
}
.menuOverlay{
  position:fixed;
  inset:0;
  background:rgba(15,23,42,.55);
  z-index:1100;
}
.syncPanel{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  border:1px solid var(--line);
  background:#f8fafc;
  border-radius:18px;
  padding:14px;
}
.syncPanel b{display:block}
.syncPanel span{display:block;color:#2563eb;font-weight:900;margin-top:4px}
.labelAdminSettings{margin-top:16px}

@media(max-width:900px){
  .hamburgerBtn{display:grid;place-items:center}
  .topbar{align-items:center}
  .sidebar{
    display:flex!important;
    position:fixed!important;
    left:0;
    top:0;
    bottom:0;
    width:280px;
    height:100dvh!important;
    z-index:1200;
    transform:translateX(-105%);
    transition:transform .22s ease;
    box-shadow:20px 0 60px rgba(0,0,0,.28);
  }
  .sidebar.open{
    transform:translateX(0);
  }
  .mobileBar{
    grid-template-columns:repeat(5,1fr);
  }
  .syncPanel{
    align-items:stretch;
    flex-direction:column;
  }
}


.rmptNativeVideo{
  width:100%;
  max-height:420px;
  object-fit:cover;
  border-radius:18px;
  background:#000;
}
#reader{
  contain:layout paint;
}


.maintenanceScreen{
  min-height:100dvh;
  display:grid;
  place-items:center;
  background:linear-gradient(135deg,#0f172a,#1e293b);
  padding:20px;
}
.maintenanceCard{
  width:min(430px,100%);
  background:#fff;
  border-radius:30px;
  padding:30px;
  text-align:center;
  box-shadow:0 30px 90px rgba(0,0,0,.3);
}
.maintenanceIcon{
  width:74px;
  height:74px;
  border-radius:26px;
  display:grid;
  place-items:center;
  background:#fef3c7;
  margin:0 auto 18px;
  font-size:38px;
}
.maintenanceCard h1{
  margin:0 0 10px;
  letter-spacing:-.03em;
}
.maintenanceCard p{
  color:#64748b;
  line-height:1.6;
}
.maintenanceAdminCard{
  margin-top:16px;
}
.fullLabel{
  display:block;
  font-weight:800;
  color:#334155;
  margin-top:12px;
}
.fullLabel input{
  margin-top:7px;
}


.maintenanceUnlock{
  display:grid;
  gap:10px;
  margin:18px 0 12px;
}
.maintenanceUnlock input{
  text-align:center;
  font-size:16px;
}
.maintenanceUnlock small{
  min-height:16px;
  color:#dc2626;
  font-weight:800;
}
.maintenanceUnlock .primary{
  width:100%;
}


.maintenanceUnlock button:not(.primary){
  width:100%;
  background:#e7edf6;
}
.maintenanceUnlock{
  grid-template-columns:1fr;
}


/* Maintenance after-login final */
.maintenanceUnlock{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  margin-top:18px;
}
.maintenanceUnlock button{
  width:100%;
}
@media(max-width:480px){
  .maintenanceUnlock{
    grid-template-columns:1fr;
  }
}


/* Mobile menu fix and modern icon UI */
.nav{display:flex;align-items:center;gap:12px;justify-content:flex-start}
.navIcon,.mobileIcon,.btnIcon,.hamburgerBtn svg,.menuFab svg,.iconBtn svg,.cameraCircleBtn svg{width:20px;height:20px;display:block;flex:0 0 auto}
.navIcon{width:18px;height:18px;opacity:.95}
.navLink{display:flex;align-items:center;gap:12px}
.mobileIcon{width:19px;height:19px}
.iconBtn,.cameraCircleBtn{display:grid;place-items:center;padding:0;min-width:46px;width:46px;height:46px}
.iconBtn svg,.cameraCircleBtn svg{width:20px;height:20px}
.topPrintBtn{display:flex;align-items:center;gap:10px}
.topPrintBtn .btnIcon{width:18px;height:18px}
.syncQuota{display:block;margin-top:6px;color:#64748b;font-size:12px;font-weight:700}
.menuFab{display:none;position:fixed;left:14px;top:14px;z-index:1305;width:46px;height:46px;padding:0;border-radius:16px;box-shadow:0 10px 28px rgba(15,23,42,.16);background:#fff;border:1px solid var(--line)}
.menuFab svg{width:22px;height:22px;margin:auto}
.hamburgerBtn{display:none;position:relative;z-index:1201;width:44px;height:44px;padding:0;border-radius:14px}
.hamburgerBtn svg{width:22px;height:22px;margin:auto}
.menuOverlay{position:fixed;inset:0;background:rgba(15,23,42,.52);z-index:1190;backdrop-filter:blur(2px)}
.scanSearchRow{display:grid;grid-template-columns:1fr auto;gap:10px;align-items:center}
.mobileBar button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;border-radius:16px;padding:8px 6px;font-size:11px;font-weight:800}
.mobileBar button .mobileIcon{width:18px;height:18px}
.emptyPreview{color:#64748b;border:1px dashed var(--line);border-radius:18px;padding:14px;background:#f8fafc}
@media(max-width:900px){
  .menuFab{display:grid;place-items:center}
  .hamburgerBtn{display:none}
  .topbar{padding-left:56px}
  .sidebar{display:flex!important;position:fixed!important;left:0;top:0;bottom:0;width:280px;height:100dvh!important;z-index:1200;transform:translateX(-108%);transition:transform .22s ease;box-shadow:20px 0 60px rgba(0,0,0,.28);pointer-events:none}
  .sidebar.open{transform:translateX(0);pointer-events:auto}
  body.menu-open{overflow:hidden}
  .mobileBar{grid-template-columns:repeat(5,1fr);padding:8px 8px calc(8px + env(safe-area-inset-bottom,0px))}
  .topActions{display:none}
}


.cameraCircleBtn[disabled]{
  opacity:.65;
  pointer-events:none;
}
.offerItem.globalOffer{
  border-color:#bfdbfe;
}


/* Professional mobile layout update */
.sideFooter{gap:10px;align-items:flex-start;justify-content:flex-start;flex-direction:column}
.sideLogoutBtn{width:100%;justify-content:center}
.topbar{padding:16px 20px;gap:16px}
.topbarTitle{min-width:0}
.topbarTitle h2{font-size:28px;letter-spacing:-.03em}
.compactTopActions{display:flex;align-items:center;gap:10px;position:relative}
.basketChip{display:flex;align-items:center;gap:8px;border-radius:999px;padding:10px 14px;background:#fff;border:1px solid var(--line);font-weight:900;box-shadow:0 6px 18px rgba(15,23,42,.06)}
.basketChip span{display:inline-grid;place-items:center;min-width:24px;height:24px;padding:0 7px;border-radius:999px;background:#eff6ff;color:#1d4ed8}
.topActionMenuWrap{position:relative}
.moreBtn{border-radius:14px;padding:10px 14px;background:#fff;border:1px solid var(--line);font-weight:900;box-shadow:0 6px 18px rgba(15,23,42,.06)}
.topMenu{position:absolute;right:0;top:calc(100% + 10px);width:210px;background:#fff;border:1px solid var(--line);border-radius:18px;box-shadow:0 22px 60px rgba(15,23,42,.16);padding:8px;display:grid;gap:6px;z-index:60}
.topMenu button{width:100%;text-align:left;border-radius:12px;padding:11px 12px;background:#f8fafc}
.topMenu button.primary,.topMenu button.danger{color:#fff}
.mobileOnly{display:none}
.productCards{display:none}
.productCard{background:#fff;border:1px solid var(--line);border-radius:20px;padding:14px;margin:10px 0;box-shadow:0 10px 26px rgba(15,23,42,.06)}
.productCardTop{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:10px}
.checkWrap{display:flex;align-items:center;gap:8px;font-weight:800;color:#334155}
.checkWrap input{width:auto}
.cardPrice{font-size:20px;font-weight:950;color:#0f172a}
.productCardName{font-size:16px;font-weight:900;line-height:1.35;margin-bottom:10px}
.productCardMeta{display:grid;grid-template-columns:1fr 1fr;gap:8px;color:#475569;font-size:13px}
.productCardMeta span{background:#f8fafc;border-radius:12px;padding:9px 10px;border:1px solid #edf2f7}
.productCardActions{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px}
.productCardActions button{flex:1 1 120px}
.scanCard{padding:16px}
.scanSearchRow{grid-template-columns:1fr auto;gap:10px}
.scanActions button{flex:1}
.toolbarBtns{display:flex;gap:8px;flex-wrap:wrap}
.syncPanel{align-items:center}
@media(max-width:900px){
  .content{padding-bottom:90px}
  .topbar{padding:14px 14px 12px 66px;align-items:flex-start}
  .topbarTitle h2{font-size:22px}
  .topbarTitle p{font-size:13px;line-height:1.4}
  .compactTopActions{margin-left:auto}
  .basketChip{padding:9px 12px;font-size:13px}
  .moreBtn{padding:9px 12px;font-size:13px}
  .topMenu{position:fixed;right:12px;top:68px;left:12px;width:auto;border-radius:18px}
  .panel{padding:10px}
  .card{border-radius:22px;padding:14px}
  .toolbar{flex-direction:column;align-items:stretch}
  .toolbar .primary,.toolbar button{width:100%}
  .bulkBar{display:grid;grid-template-columns:1fr 1fr;gap:8px}
  .bulkBar .primary{grid-column:1/-1}
  .bulkBar span{grid-column:1/-1}
  .tableWrap{display:none}
  .mobileOnly,.productCards{display:block}
  .pager{justify-content:space-between}
  .mobileBar{background:rgba(255,255,255,.96);backdrop-filter:blur(12px);box-shadow:0 -10px 28px rgba(15,23,42,.08)}
  .mobileBar button{padding:8px 4px;font-size:10.5px}
  .mobileBar button.primary{border-radius:14px}
  .menuFab{top:12px;left:12px;width:44px;height:44px;border-radius:14px}
  .sidebar{padding:16px 14px 18px}
  .searchBar{grid-template-columns:1fr auto}
  .searchBar input{min-width:0}
  .productCardMeta{grid-template-columns:1fr}
  .settingsGrid label,.toggleGrid label{font-size:13px}
}
@media(max-width:480px){
  .bulkBar{grid-template-columns:1fr}
  .basketChip{display:none}
  .topbar{padding-right:12px}
  .topMenu{top:62px}
  .scanActions,.buttonRow{display:grid;grid-template-columns:1fr 1fr;gap:8px}
  .scanActions .primary,.buttonRow .primary{grid-column:auto}
  .productCardActions{display:grid;grid-template-columns:1fr 1fr}
  .productCardActions button:first-child{grid-column:1/-1}
}


/* ============================================================
   RMPT MOBILE HARD OVERRIDE FINAL
   Forces clean mobile layout and overrides all old mobile CSS.
   ============================================================ */

.sideFooter{
  gap:10px !important;
  align-items:stretch !important;
  justify-content:flex-start !important;
  flex-direction:column !important;
}
.sideLogoutBtn{
  width:100% !important;
  background:#dc2626 !important;
  color:#fff !important;
  text-align:center !important;
  justify-content:center !important;
}
.compactTopActions{
  display:flex !important;
  align-items:center !important;
  gap:10px !important;
  position:relative !important;
}
.basketChip{
  display:flex !important;
  align-items:center !important;
  gap:8px !important;
  border-radius:999px !important;
  padding:10px 14px !important;
  background:#fff !important;
  border:1px solid var(--line) !important;
  font-weight:900 !important;
}
.basketChip span{
  display:inline-grid !important;
  place-items:center !important;
  min-width:24px !important;
  height:24px !important;
  padding:0 7px !important;
  border-radius:999px !important;
  background:#eff6ff !important;
  color:#1d4ed8 !important;
}
.topActionMenuWrap{
  position:relative !important;
}
.moreBtn{
  border-radius:14px !important;
  padding:10px 14px !important;
  background:#fff !important;
  border:1px solid var(--line) !important;
  font-weight:900 !important;
}
.topMenu{
  position:absolute !important;
  right:0 !important;
  top:calc(100% + 10px) !important;
  width:220px !important;
  background:#fff !important;
  border:1px solid var(--line) !important;
  border-radius:18px !important;
  box-shadow:0 22px 60px rgba(15,23,42,.18) !important;
  padding:8px !important;
  display:grid !important;
  gap:6px !important;
  z-index:2000 !important;
}
.topMenu.hidden{
  display:none !important;
}
.topMenu button{
  width:100% !important;
  text-align:left !important;
  border-radius:12px !important;
  padding:12px !important;
  background:#f8fafc !important;
}
.topMenu button.danger{
  background:#dc2626 !important;
  color:#fff !important;
}
.productCards{
  display:none;
}
.productCard{
  background:#fff !important;
  border:1px solid var(--line) !important;
  border-radius:20px !important;
  padding:14px !important;
  margin:10px 0 !important;
  box-shadow:0 10px 26px rgba(15,23,42,.06) !important;
}
.productCardTop{
  display:flex !important;
  align-items:center !important;
  justify-content:space-between !important;
  gap:8px !important;
  margin-bottom:10px !important;
}
.checkWrap{
  display:flex !important;
  align-items:center !important;
  gap:8px !important;
  font-weight:800 !important;
  color:#334155 !important;
}
.checkWrap input{
  width:auto !important;
}
.cardPrice{
  font-size:20px !important;
  font-weight:950 !important;
  color:#0f172a !important;
}
.productCardName{
  font-size:16px !important;
  font-weight:900 !important;
  line-height:1.35 !important;
  margin-bottom:10px !important;
}
.productCardMeta{
  display:grid !important;
  grid-template-columns:1fr 1fr !important;
  gap:8px !important;
  color:#475569 !important;
  font-size:13px !important;
}
.productCardMeta span{
  background:#f8fafc !important;
  border-radius:12px !important;
  padding:9px 10px !important;
  border:1px solid #edf2f7 !important;
  overflow-wrap:anywhere !important;
}
.productCardActions{
  display:flex !important;
  gap:8px !important;
  flex-wrap:wrap !important;
  margin-top:12px !important;
}
.productCardActions button{
  flex:1 1 120px !important;
}
.mobileOnly{
  display:none;
}

@media(max-width:900px){
  html,body{
    max-width:100% !important;
    overflow-x:hidden !important;
  }
  .app{
    display:block !important;
    min-height:100dvh !important;
  }
  .content{
    width:100% !important;
    padding-bottom:96px !important;
  }
  .topbar{
    position:sticky !important;
    top:0 !important;
    z-index:900 !important;
    padding:12px 12px 12px 64px !important;
    min-height:64px !important;
    display:flex !important;
    align-items:flex-start !important;
    gap:8px !important;
    background:rgba(238,243,249,.96) !important;
    border-bottom:1px solid var(--line) !important;
    backdrop-filter:blur(12px) !important;
  }
  .topbarTitle{
    min-width:0 !important;
    flex:1 !important;
  }
  .topbarTitle h2,
  .topbar h2{
    margin:0 !important;
    font-size:21px !important;
    line-height:1.1 !important;
    letter-spacing:-.03em !important;
  }
  .topbarTitle p,
  .topbar p{
    margin:4px 0 0 !important;
    font-size:12.5px !important;
    line-height:1.3 !important;
    color:#64748b !important;
  }
  .topActions,
  .compactTopActions{
    display:flex !important;
    margin-left:auto !important;
    gap:6px !important;
  }
  .basketChip{
    display:none !important;
  }
  .moreBtn{
    padding:9px 11px !important;
    font-size:13px !important;
    border-radius:13px !important;
    background:#0f172a !important;
    color:#fff !important;
    border-color:#0f172a !important;
  }
  .topMenu{
    position:fixed !important;
    left:12px !important;
    right:12px !important;
    top:68px !important;
    width:auto !important;
    z-index:2100 !important;
    border-radius:20px !important;
  }
  .menuFab{
    display:grid !important;
    place-items:center !important;
    position:fixed !important;
    top:12px !important;
    left:12px !important;
    z-index:1600 !important;
    width:44px !important;
    height:44px !important;
    border-radius:14px !important;
    background:#fff !important;
    border:1px solid var(--line) !important;
    box-shadow:0 10px 28px rgba(15,23,42,.16) !important;
    padding:0 !important;
  }
  .menuFab svg{
    width:22px !important;
    height:22px !important;
  }
  .hamburgerBtn{
    display:none !important;
  }
  .menuOverlay{
    position:fixed !important;
    inset:0 !important;
    background:rgba(15,23,42,.56) !important;
    z-index:1400 !important;
    backdrop-filter:blur(2px) !important;
  }
  .menuOverlay.hidden{
    display:none !important;
  }
  .sidebar{
    display:flex !important;
    position:fixed !important;
    left:0 !important;
    top:0 !important;
    bottom:0 !important;
    width:min(82vw,310px) !important;
    height:100dvh !important;
    z-index:1500 !important;
    transform:translateX(-110%) !important;
    transition:transform .22s ease !important;
    box-shadow:20px 0 60px rgba(0,0,0,.28) !important;
    pointer-events:none !important;
    padding:16px 14px 18px !important;
    overflow-y:auto !important;
  }
  .sidebar.open{
    transform:translateX(0) !important;
    pointer-events:auto !important;
  }
  body.menu-open{
    overflow:hidden !important;
  }
  .nav{
    display:flex !important;
    align-items:center !important;
    gap:12px !important;
    width:100% !important;
    min-height:44px !important;
    border-radius:14px !important;
  }
  .navIcon{
    width:19px !important;
    height:19px !important;
  }
  .sideFooter{
    margin-top:auto !important;
    display:flex !important;
    flex-direction:column !important;
    gap:10px !important;
    align-items:stretch !important;
  }
  .sideLogoutBtn{
    width:100% !important;
    padding:12px !important;
    border-radius:14px !important;
  }
  .panel{
    padding:10px !important;
  }
  .card{
    border-radius:22px !important;
    padding:14px !important;
  }
  .toolbar{
    display:flex !important;
    flex-direction:column !important;
    align-items:stretch !important;
    gap:12px !important;
  }
  .toolbar h3{
    font-size:18px !important;
  }
  .toolbar button,
  .toolbar .primary{
    width:100% !important;
  }
  .searchBar{
    display:grid !important;
    grid-template-columns:1fr 48px !important;
    gap:8px !important;
  }
  .searchBar input{
    min-width:0 !important;
    height:48px !important;
    font-size:15px !important;
  }
  .iconBtn{
    width:48px !important;
    min-width:48px !important;
    height:48px !important;
  }
  .bulkBar{
    display:grid !important;
    grid-template-columns:1fr 1fr !important;
    gap:8px !important;
    align-items:stretch !important;
  }
  .bulkBar .primary{
    grid-column:1/-1 !important;
  }
  .bulkBar span{
    grid-column:1/-1 !important;
    width:100% !important;
    margin-left:0 !important;
    text-align:center !important;
  }
  .tableWrap{
    display:none !important;
  }
  .productCards,
  .mobileOnly{
    display:block !important;
  }
  .productCardMeta{
    grid-template-columns:1fr !important;
  }
  .productCardActions{
    display:grid !important;
    grid-template-columns:1fr 1fr !important;
  }
  .productCardActions button:first-child{
    grid-column:1/-1 !important;
  }
  .pager{
    display:flex !important;
    justify-content:space-between !important;
    gap:8px !important;
  }
  .pager button{
    flex:1 !important;
  }
  .scanCard{
    padding:14px !important;
  }
  .scanSearchRow{
    display:grid !important;
    grid-template-columns:1fr 52px !important;
    gap:8px !important;
  }
  .scanSearchRow input{
    height:52px !important;
    font-size:15px !important;
  }
  .cameraCircleBtn{
    width:52px !important;
    min-width:52px !important;
    height:52px !important;
    padding:0 !important;
  }
  #reader{
    max-width:100% !important;
    min-height:285px !important;
    border-radius:18px !important;
  }
  .scanActions,
  .buttonRow{
    display:grid !important;
    grid-template-columns:1fr 1fr !important;
    gap:8px !important;
  }
  .scanActions button,
  .buttonRow button{
    width:100% !important;
  }
  .basketList,
  .settingsGrid,
  .toggleGrid,
  .editGrid,
  .offerList{
    display:grid !important;
    grid-template-columns:1fr !important;
  }
  .syncPanel{
    display:flex !important;
    flex-direction:column !important;
    align-items:stretch !important;
    gap:12px !important;
  }
  .mobileBar{
    position:fixed !important;
    bottom:0 !important;
    left:0 !important;
    right:0 !important;
    z-index:1300 !important;
    background:rgba(255,255,255,.97) !important;
    border-top:1px solid var(--line) !important;
    display:grid !important;
    grid-template-columns:repeat(5,1fr) !important;
    gap:4px !important;
    padding:8px 8px calc(8px + env(safe-area-inset-bottom,0px)) !important;
    box-shadow:0 -10px 28px rgba(15,23,42,.08) !important;
    backdrop-filter:blur(12px) !important;
  }
  .mobileBar button{
    display:flex !important;
    flex-direction:column !important;
    align-items:center !important;
    justify-content:center !important;
    gap:4px !important;
    padding:8px 3px !important;
    border-radius:14px !important;
    font-size:10.5px !important;
    font-weight:850 !important;
  }
  .mobileIcon{
    width:18px !important;
    height:18px !important;
  }
}

@media(max-width:420px){
  .topbar{
    padding-right:8px !important;
  }
  .moreBtn{
    padding:9px 10px !important;
  }
  .bulkBar,
  .scanActions,
  .buttonRow{
    grid-template-columns:1fr !important;
  }
}

/* Proper software letterpad module */
.letterpadShell{padding:4px 0 84px}.letterpadHeader{display:flex;justify-content:space-between;gap:16px;align-items:center;margin:0 0 18px}.letterpadHeader h3{font-size:24px;margin:0 0 4px}.letterpadHeader p{margin:0;color:#64748b}.managerBadge{background:#dcfce7;color:#166534;border:1px solid #bbf7d0;border-radius:12px;padding:9px 13px;font-weight:800;font-size:12px}.letterpadGrid{display:grid;grid-template-columns:minmax(360px,.95fr) minmax(480px,1.05fr);gap:22px;align-items:start}.letterFormCard,.previewCard{background:#fff;border:1px solid #e5e7eb;border-radius:16px;box-shadow:0 10px 30px rgba(15,23,42,.08)}.letterFormCard{padding:18px;display:grid;gap:13px}.letterFormCard label{display:grid;gap:7px;font-size:12px;font-weight:850;color:#111827}.letterFormCard input,.letterFormCard select,.letterFormCard textarea{border:1px solid #dbe2ea;border-radius:10px;padding:12px;background:#fff;font:inherit}.letterFormCard textarea{resize:vertical}.formRow.two{display:grid;grid-template-columns:1fr 1fr;gap:14px}.signatureBox{display:grid;gap:7px;font-size:12px;font-weight:850}.signatureBox canvas{width:100%;height:92px;background:#fff;border:1px dashed #94a3b8;border-radius:12px;touch-action:none}.signatureBox button{justify-self:end;padding:6px 10px}.previewCard{padding:16px}.previewToolbar{display:flex;justify-content:space-between;align-items:center;margin-bottom:12px}.previewToolbar button{padding:8px 12px;border-radius:10px}.letterPreview.properLetter{width:min(100%,595px);aspect-ratio:210/297;margin:0 auto;background:#fff;color:#0f172a;border-radius:4px;box-shadow:0 10px 30px rgba(15,23,42,.12);overflow:hidden;transform-origin:top center}.letterPreview.fitA4{max-height:78vh;overflow:auto}.lpPage{width:100%;height:100%;padding:7.5% 9.5% 10.5%;position:relative;background:#fff;font-family:Arial,Helvetica,sans-serif}.lpHeader{display:flex;justify-content:space-between;align-items:flex-start}.lpLogo{width:34%;max-width:220px;height:auto;object-fit:contain;margin-top:0}.lpContact{font-size:1.95%;font-weight:800;line-height:1.75;margin-top:2.2%;white-space:nowrap}.lpRule{height:2px;background:#111827;margin-top:4.5%}.lpMain{font-size:2.06%;line-height:1.55;margin-top:5.5%}.lpDate{text-align:right;margin-bottom:4.5%}.lpRecipient{margin-bottom:4.5%}.lpSubject{font-weight:800;margin:3.2% 0 5%;display:flex;gap:2%;align-items:flex-end}.lpSubject span:first-of-type{display:inline-block;min-width:55%;border-bottom:1.5px solid #111827;min-height:15px}.lpSalutation{margin-bottom:4.5%}.lpBody{min-height:26%;white-space:normal}.lpClose{margin-top:6%}.lpSign{margin-top:7%}.letterSig{max-width:28%;max-height:60px;display:block;margin-bottom:5px}.sigLine{width:28%;border-top:1.5px solid #111827;margin-bottom:6px}.lpFooter{position:absolute;left:9.5%;right:9.5%;bottom:3.3%;text-align:center;border-top:1.5px solid #111827;padding-top:2.8%;font-size:1.75%;line-height:1.45}.mutedText{color:#94a3b8}.letterActionBar{position:sticky;bottom:0;z-index:5;margin-top:18px;background:rgba(255,255,255,.96);border:1px solid #e5e7eb;border-radius:16px;box-shadow:0 -8px 24px rgba(15,23,42,.08);padding:14px 18px;display:flex;justify-content:space-between;align-items:center;gap:12px}.letterActionBar>div{display:flex;gap:10px}.templateSave{display:flex;gap:8px;align-items:center;font-weight:800}.infoPageCard{max-width:980px;margin:auto}.infoPageCard h2{font-size:28px}.helpGrid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin-top:18px}.helpGrid>div{border:1px solid #e5e7eb;border-radius:16px;padding:16px;background:#f8fafc}.navLink{border:0;background:transparent;width:100%;font:inherit;text-align:left}.labelAdminSettings{display:block!important}
@media(max-width:1180px){.letterpadGrid{grid-template-columns:1fr}.letterPreview.properLetter{max-width:700px}.helpGrid{grid-template-columns:1fr}.lpContact{font-size:2.15%}.lpMain{font-size:2.25%}.lpFooter{font-size:1.95%}}
@media(max-width:720px){.letterpadHeader,.letterActionBar{align-items:stretch;flex-direction:column}.formRow.two{grid-template-columns:1fr}.letterFormCard,.previewCard{padding:13px}.letterPreview.properLetter{width:100%;}.lpContact{font-size:2.5%;}.lpMain{font-size:2.55%;}.lpFooter{font-size:2.1%;}}

/* v16 restored full label studio + letterpad templates */
.sizeLockBanner{display:flex;align-items:center;gap:12px;padding:13px 15px;margin:12px 0 18px;border:1px solid #bbf7d0;background:#f0fdf4;border-radius:16px;color:#166534}.sizeLockBanner>span{font-size:24px}.sizeLockBanner b,.sizeLockBanner small{display:block}.sizeLockBanner small{margin-top:3px;color:#4b5563}.sectionTitle{margin:0 0 10px;font-size:13px;text-transform:uppercase;letter-spacing:.08em;color:#64748b}.templateGallery{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:10px;margin:12px 0 18px}.templateCard{border:2px solid transparent;border-radius:16px;padding:8px;background:#f8fafc;cursor:pointer;text-align:left;transition:.18s ease}.templateCard:hover{transform:translateY(-1px);box-shadow:0 8px 22px #0f172a14}.templateCard.active{border-color:#2563eb;background:#eff6ff}.templateSwatch{height:66px;border-radius:12px;border:1px solid #0f172a22;display:flex;align-items:flex-end;position:relative;padding:8px;font-size:11px;font-weight:900;overflow:hidden}.templateSwatch i{position:absolute;left:0;right:0;top:0;height:7px}.templateSwatch b{position:relative;z-index:1}.designerLayout{display:grid;grid-template-columns:minmax(340px,1fr) minmax(360px,.75fr);gap:20px;align-items:start}.compactSettings{grid-template-columns:repeat(2,minmax(0,1fr))}.compactSettings input[type=color]{height:42px;padding:3px}.sheetAdvanced{margin:14px 0;border:1px solid var(--line);border-radius:14px;padding:12px;background:#f8fafc}.sheetAdvanced summary{cursor:pointer;font-weight:850;color:#334155}.sheetAdvanced .settingsGrid{margin-top:12px}.advancedPreview{min-height:230px!important;margin-top:0;background:linear-gradient(135deg,#f8fafc,#eef2ff)!important;display:grid;place-items:center;border-radius:16px;border:1px solid #e5e7eb}.advancedLabelMock{width:330px;max-width:94%;aspect-ratio:46.775/34;min-height:0!important;padding:18px 14px 10px!important;overflow:hidden;border-radius:6px;display:flex;flex-direction:column;justify-content:center;position:relative;border:2px solid}.advancedLabelMock .labelAccent{position:absolute;left:0;right:0;top:0;height:9px}.advancedLabelMock .catPreview{font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.08em;opacity:.86}.advancedLabelMock .p1{font-size:18px;font-weight:900;line-height:1.08}.advancedLabelMock .p2{font-size:13px;opacity:.9}.advancedLabelMock .price{font-size:20px;font-weight:950;margin:3px 0}.advancedLabelMock .fakeBarcode{width:80%;height:24px;margin:4px auto 1px;background:repeating-linear-gradient(90deg,#111 0 2px,#fff 2px 4px,#111 4px 5px,#fff 5px 8px);border:4px solid #fff;box-sizing:content-box}.advancedLabelMock .barcodeText{text-align:center;font-size:10px;letter-spacing:.08em}.letterTemplatePanel{background:#fff;border:1px solid #e5e7eb;border-radius:16px;padding:14px 16px;margin-bottom:16px;box-shadow:0 8px 24px rgba(15,23,42,.06)}.letterTemplateGallery{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:10px}.letterTemplateBtn{border:1px solid #dbe2ea;background:#f8fafc;border-radius:12px;padding:10px;font-weight:850;cursor:pointer}.letterTemplateBtn.active{background:#eff6ff;border-color:#2563eb;color:#1d4ed8}.lpTemplate-clean .lpRule,.lpTemplate-clean .lpFooter{border-color:#111827}.lpTemplate-corporate .lpRule{background:#0b3a75}.lpTemplate-corporate .lpFooter{border-top-color:#0b3a75}.lpTemplate-modern .lpRule{height:1px;background:#94a3b8}.lpTemplate-modern .lpFooter{border-top-color:#94a3b8}.lpTemplate-formal{font-family:Georgia,'Times New Roman',serif}.lpTemplate-formal .lpRule{background:#111827}.lpTemplate-executive .lpRule{background:#b8912b}.lpTemplate-executive .lpFooter{border-top-color:#b8912b}.lpTemplate-compact .lpMain{margin-top:4.2%;font-size:1.95%}.lpTemplate-compact .lpFooter{font-size:1.55%;padding-top:2%}
@media(max-width:1100px){.designerLayout{grid-template-columns:1fr}.templateGallery,.letterTemplateGallery{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:700px){.templateGallery,.letterTemplateGallery{grid-template-columns:repeat(2,1fr)}.compactSettings{grid-template-columns:1fr}.advancedLabelMock{width:290px}}

/* v17 stability fixes: professional letterpad + restored PDQ print centre */
.printCentreCard{border:1px solid #bfdbfe!important;background:linear-gradient(180deg,#fff,#f8fbff);margin-top:18px}.printModeGrid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:12px 0}.printModeOption{display:flex;align-items:center;gap:10px;border:1px solid var(--line);border-radius:16px;padding:14px;background:#fff;cursor:pointer}.printModeOption:has(input:checked){border-color:#2563eb;box-shadow:0 0 0 2px #dbeafe}.printModeOption span b,.printModeOption span small{display:block}.printModeOption span small{color:#64748b;margin-top:3px}.printRangeGrid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.printRangeGrid label{font-size:12px;font-weight:800;color:#475569}.printRangeGrid input,.printRangeGrid select{width:100%;margin-top:6px}
.slimToolbar{align-items:flex-start}.slimToolbar p{margin:3px 0 0;color:#64748b;font-size:12px}.letterSettingsBox{margin-top:14px;border:1px solid #e5e7eb;border-radius:14px;background:#f8fafc;padding:12px}.letterSettingsBox summary{cursor:pointer;font-weight:900;color:#334155}.letterSettingsGrid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin-top:12px}.letterSettingsGrid label{display:grid;gap:6px;font-size:12px;font-weight:850}.letterSettingsGrid input,.letterSettingsGrid textarea,.letterSettingsGrid select{border:1px solid #dbe2ea;border-radius:10px;padding:10px;background:#fff;font:inherit}.letterToggles{margin-top:10px}.letterTemplateBtn{display:grid!important;gap:4px;text-align:left}.letterTemplateBtn b{font-size:12px}.letterTemplateBtn small{font-size:10px;color:#64748b;font-weight:700}.lpHeader{gap:10%;align-items:flex-start!important}.lpHeaderRight{text-align:left;margin-top:1.8%}.lpContact{font-size:1.95%!important;font-weight:850!important;line-height:1.65!important;margin-top:0!important;white-space:nowrap}.lpTopAddress{font-size:1.55%;line-height:1.35;margin-top:1.7%;color:#334155}.lpRule{height:1.6px!important;margin-top:3.8%!important}.lpMain{margin-top:4.8%!important;font-size:2.05%!important;line-height:1.56!important}.lpDate{margin-bottom:4%!important}.lpRecipient{margin-bottom:4%!important}.lpSubject{margin:3% 0 4.6%!important}.lpSubject span:first-of-type{border-bottom:1px solid #111827!important;min-height:13px!important}.lpCase{font-size:85%;color:#475569;font-weight:700}.lpBody{min-height:33%!important;white-space:normal}.lpClose{margin:0 0 2.7%!important}.lpSignBlock{margin-top:5.5%!important}.lpSigner{line-height:1.5}.letterSig{max-width:28%;max-height:54px;display:block;margin:0 0 8px}.lpFooter{font-size:1.65%!important;line-height:1.45!important;padding-top:2.4%!important;bottom:3.2%!important}.sigLine,.lpSign{display:none!important}.lpTemplate-legalMinimal .lpRule{height:1px!important;background:#cbd5e1!important}.lpTemplate-legalMinimal .lpFooter{border-top:1px solid #cbd5e1!important}.lpTemplate-executive .lpRule{background:#b8912b!important}.lpTemplate-executive .lpFooter{border-top-color:#b8912b!important}.lpTemplate-formal{font-family:Georgia,'Times New Roman',serif!important}.lpTemplate-bottomAddress .lpContact{margin-top:2.5%!important}.lpTemplate-topAddress .lpHeaderRight{max-width:43%}.lpTemplate-topClean .lpLogo,.lpTemplate-legalMinimal .lpLogo{width:32%!important}
@media(max-width:900px){.printModeGrid,.printRangeGrid,.letterSettingsGrid{grid-template-columns:1fr}.lpContact{font-size:2.45%!important}.lpTopAddress{font-size:2.05%}.lpMain{font-size:2.45%!important}.lpFooter{font-size:2.05%!important}}

/* v18 professional software polish: single customizable letterpad, no subject underline, no footer collision */
.softwarePanel{background:linear-gradient(180deg,#ffffff,#f8fafc);border:1px solid #dbeafe!important;box-shadow:0 16px 40px rgba(15,23,42,.08)!important}
.singleLetterDesignBadge{grid-column:1/-1;display:flex;justify-content:space-between;gap:16px;align-items:center;padding:14px 16px;border:1px solid #dbeafe;border-radius:14px;background:#eff6ff;color:#0f172a}.singleLetterDesignBadge b,.singleLetterDesignBadge small{display:block}.singleLetterDesignBadge small{color:#475569;margin-top:3px}.wideField{grid-column:span 2}.letterSettingsGrid{grid-template-columns:repeat(4,minmax(0,1fr))!important}.letterSettingsGrid input,.letterSettingsGrid textarea,.letterSettingsGrid select{min-height:40px}.letterPreview.properLetter{background:#f8fafc!important;padding:0!important}.lpSingleDesign{padding:7.2% 9.5% 14.8%!important;overflow:hidden!important}.lpSingleDesign .lpHeader{gap:8%;align-items:flex-start!important}.lpSingleDesign .lpLogo{width:33%!important;max-width:210px!important;margin:0!important}.lpSingleDesign .lpHeaderRight{max-width:45%;margin-top:1.4%!important}.lpSingleDesign .lpContact{font-size:1.9%!important;line-height:1.68!important;font-weight:850!important;white-space:nowrap}.lpSingleDesign .lpTopAddress{font-size:1.48%!important;line-height:1.35!important;margin-top:1.8%!important;color:#334155}.lpSingleDesign .lpRule{height:1.2px!important;background:#111827!important;margin-top:3.2%!important}.lpSingleDesign .lpMain{margin-top:4.4%!important;font-size:2.02%!important;line-height:1.55!important}.lpSingleDesign .lpDate{margin-bottom:3.8%!important;text-align:right}.lpSingleDesign .lpRecipient{margin-bottom:3.8%!important}.lpSingleDesign .lpSubject{font-weight:800!important;margin:2.7% 0 4.2%!important;display:block!important;border:0!important}.lpSingleDesign .lpSubject span:first-of-type{border:0!important;min-width:0!important;min-height:0!important}.lpSingleDesign .lpCase{margin-left:2.5%;font-size:85%;color:#475569;font-weight:800}.lpSingleDesign .lpSalutation{margin-bottom:4.2%!important}.lpSingleDesign .lpBody{min-height:calc(var(--lp-body-min,88mm) * .335)!important;white-space:normal!important}.lpSingleDesign .lpSignBlock{margin-top:calc(var(--lp-sign-gap,10mm) * .33)!important;line-height:1.45!important;max-width:52%;clear:both}.lpSingleDesign .lpSign-center{text-align:center;margin-left:auto!important;margin-right:auto!important}.lpSingleDesign .lpSign-right{text-align:right;margin-left:auto!important}.lpSingleDesign .lpClose{margin:0 0 2.5%!important}.lpSingleDesign .letterSig{max-width:52%!important;max-height:54px!important;display:block;margin:0 0 6px!important}.lpSingleDesign .lpSign-center .letterSig{margin-left:auto!important;margin-right:auto!important}.lpSingleDesign .lpSign-right .letterSig{margin-left:auto!important}.lpSingleDesign .lpSigner{line-height:1.45!important}.lpSingleDesign .lpFooter{left:9.5%!important;right:9.5%!important;bottom:calc(var(--lp-footer-gap,12mm) * .34)!important;text-align:center!important;border-top:1px solid #111827!important;padding-top:2.2%!important;font-size:1.52%!important;line-height:1.42!important;background:#fff}.sigLine,.lpSign{display:none!important}.letterActionBar span{font-size:12px;font-weight:800;color:#475569}.offerDesignerPanel{margin:14px 0 18px;padding:16px;border:1px solid #dbeafe;border-radius:18px;background:linear-gradient(180deg,#fff,#f8fbff);box-shadow:0 12px 30px rgba(15,23,42,.06)}.offerTemplateGallery{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:10px;margin:10px 0 14px}.offerTemplateBtn{border:2px solid transparent;background:#fff;border-radius:15px;padding:8px;cursor:pointer}.offerTemplateBtn.active{border-color:#2563eb;background:#eff6ff}.offerTemplateBtn span{height:58px;border:1px solid #dbe2ea;border-radius:11px;display:flex;align-items:flex-end;padding:8px;font-size:11px;font-weight:900;position:relative;overflow:hidden}.offerTemplateBtn i{position:absolute;left:0;right:0;top:0;height:7px}.templateCard .templateSwatch{box-shadow:inset 0 0 0 1px rgba(255,255,255,.45)}.templateCard:hover,.offerTemplateBtn:hover{transform:translateY(-2px);transition:.18s ease}.card,.letterFormCard,.previewCard,.printCentreCard{border-radius:20px!important}.primary,button{transition:transform .16s ease,box-shadow .16s ease}button:hover{transform:translateY(-1px)}
@media(max-width:1200px){.letterSettingsGrid{grid-template-columns:repeat(2,minmax(0,1fr))!important}.offerTemplateGallery{grid-template-columns:repeat(3,minmax(0,1fr))}.wideField{grid-column:span 2}}
@media(max-width:700px){.letterSettingsGrid,.offerTemplateGallery{grid-template-columns:1fr!important}.wideField{grid-column:span 1}.lpSingleDesign .lpHeader{flex-direction:column}.lpSingleDesign .lpHeaderRight{max-width:100%}.lpSingleDesign .lpSignBlock{max-width:80%}}


/* v19 SAFE RESTORE: keep every module visible, fix letter preview scaling, no subject line, no footer collision */
#products,#scan,#selected,#settings,#offers,#letterpad,#help,#privacy,#upload,#admin{min-height:120px}.advancedLabelCard,.printCentreCard,.offerDesignerPanel,.letterTemplatePanel,.letterFormCard,.previewCard{display:block!important}.templateGallery,.offerTemplateGallery{min-height:74px}.letterTemplateGallery{display:grid!important}.printCentreCard{display:block!important}.printModeGrid,.printRangeGrid{display:grid!important}.lpPage.lpSingleDesign{width:100%!important;height:100%!important;padding:42px 56px 96px!important;overflow:hidden!important;position:relative!important;background:#fff!important;box-sizing:border-box!important}.lpSingleDesign .lpHeader{display:flex!important;justify-content:space-between!important;align-items:flex-start!important;gap:36px!important}.lpSingleDesign .lpLogo{width:190px!important;max-width:42%!important;height:auto!important;margin:0!important}.lpSingleDesign .lpHeaderRight{max-width:250px!important;margin-top:6px!important;text-align:left!important}.lpSingleDesign .lpContact{font-size:11px!important;line-height:1.55!important;font-weight:750!important;white-space:nowrap!important}.lpSingleDesign .lpTopAddress{font-size:9px!important;line-height:1.35!important;margin-top:8px!important;color:#334155!important}.lpSingleDesign .lpRule{height:1px!important;background:#111827!important;margin-top:22px!important}.lpSingleDesign .lpMain{margin-top:26px!important;font-size:12px!important;line-height:1.55!important;color:#111827!important}.lpSingleDesign .lpDate{text-align:right!important;margin-bottom:22px!important}.lpSingleDesign .lpRecipient{margin-bottom:20px!important}.lpSingleDesign .lpSubject{display:block!important;border:0!important;margin:14px 0 20px!important;font-weight:750!important}.lpSingleDesign .lpSubject span:first-of-type{border:0!important;min-width:0!important;min-height:0!important}.lpSingleDesign .lpCase{margin-left:12px!important;font-size:10px!important;color:#475569!important;font-weight:650!important}.lpSingleDesign .lpSalutation{margin-bottom:18px!important}.lpSingleDesign .lpBody{min-height:180px!important;white-space:normal!important;overflow:hidden!important}.lpSingleDesign .lpSignBlock{margin-top:22px!important;line-height:1.45!important;max-width:310px!important;clear:both!important}.lpSingleDesign .lpSign-center{text-align:center!important;margin-left:auto!important;margin-right:auto!important}.lpSingleDesign .lpSign-right{text-align:right!important;margin-left:auto!important}.lpSingleDesign .lpClose{margin:0 0 10px!important}.lpSingleDesign .letterSig{max-width:160px!important;max-height:52px!important;display:block!important;margin:0 0 7px!important}.lpSingleDesign .lpSign-center .letterSig{margin-left:auto!important;margin-right:auto!important}.lpSingleDesign .lpSign-right .letterSig{margin-left:auto!important}.lpSingleDesign .lpSigner{line-height:1.42!important}.lpSingleDesign .lpRole{font-weight:400!important;color:#334155!important}.lpSingleDesign .lpFooter{position:absolute!important;left:56px!important;right:56px!important;bottom:32px!important;text-align:center!important;border-top:1px solid #111827!important;padding-top:11px!important;font-size:9px!important;line-height:1.38!important;background:#fff!important}.letterPreview.properLetter{background:#fff!important}.singleLetterDesignBadge{display:flex!important}.letterActionBar{z-index:30}.offerDesignerPanel .compactSettings,.advancedLabelCard .compactSettings{display:grid!important}.oldTemplateNote{font-size:12px;color:#64748b;font-weight:800;margin:0 0 8px}
@media(max-width:900px){.lpSingleDesign .lpContact{font-size:10px!important}.lpSingleDesign .lpMain{font-size:11px!important}.lpSingleDesign .lpFooter{font-size:8px!important}.lpSingleDesign .lpLogo{width:160px!important}.lpSingleDesign .lpHeaderRight{max-width:220px!important}}

/* v20 offer PDQ + reliable preview polish */
.offerDesignerGrid{display:grid;grid-template-columns:minmax(360px,1fr) minmax(300px,.65fr);gap:18px;align-items:start}.offerPreviewPanel{border:1px solid #dbeafe;border-radius:16px;background:#fff;padding:14px;min-height:210px}.offerPreview{display:grid;place-items:center;min-height:160px;background:linear-gradient(135deg,#f8fafc,#eef2ff);border:1px solid #e5e7eb;border-radius:14px;padding:18px}.offerMock{width:330px;max-width:96%;aspect-ratio:46.775/34;border:2px solid;border-radius:7px;overflow:hidden;box-shadow:0 12px 28px rgba(15,23,42,.12);position:relative;font-family:Arial,Helvetica,sans-serif}.offerMockHead{height:30px;display:grid;place-items:center;font-size:15px;font-weight:950;letter-spacing:.06em}.offerMockNote{text-align:center;font-size:10px;font-weight:900;text-transform:uppercase;margin-top:5px;letter-spacing:.05em}.offerMockName{text-align:center;font-size:16px;font-weight:950;line-height:1.05;margin:6px 12px 0}.offerMockDesc{text-align:center;font-size:12px;line-height:1.1;margin:2px 12px 0;opacity:.82}.offerMockPrices{display:flex;align-items:end;justify-content:space-between;margin:7px 16px 0}.offerMockPrices span small,.offerMockPrices strong small{display:block;font-size:9px;line-height:1;font-weight:900;letter-spacing:.08em}.offerMockPrices span b{font-size:14px;color:#64748b;text-decoration:line-through}.offerMockPrices strong{font-size:22px;line-height:.95;text-align:right}.offerBarcodeMock{height:24px;margin:7px auto 0;width:76%;background:repeating-linear-gradient(90deg,#111 0 2px,#fff 2px 4px,#111 4px 5px,#fff 5px 8px);border:4px solid #fff;box-sizing:content-box}.offerBarcodeText{text-align:center;font-size:9px;letter-spacing:.08em;color:#111}.offerPrintCard{margin:16px 0 18px!important}.lpLogoFallback{font-size:20px;font-weight:950;line-height:1.05;max-width:190px;color:#111827}.letterPreview.properLetter{min-height:842px!important;display:block!important}.letterPreview.properLetter .lpPage{min-height:842px!important}.lpSingleDesign .lpHeader{min-height:82px!important}.lpSingleDesign .lpLogo{display:block!important;object-fit:contain!important}.lpSingleDesign .lpBody{min-height:170px!important;max-height:310px!important;overflow:hidden!important}.lpSingleDesign .lpSignBlock{margin-bottom:72px!important}.lpSingleDesign .lpFooter{z-index:2!important}.lpSingleDesign .lpSubject{border-bottom:0!important;text-decoration:none!important}.lpSingleDesign .lpSubject:after,.lpSingleDesign .lpSubject:before{display:none!important}
@media(max-width:1000px){.offerDesignerGrid{grid-template-columns:1fr}.offerMock{width:310px}.letterPreview.properLetter{min-height:720px!important}.letterPreview.properLetter .lpPage{min-height:720px!important}}

/* v21 restored admin dashboard */
.adminDashboardGrid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:18px}.adminStatCard{background:linear-gradient(135deg,#ffffff,#f8fafc);border:1px solid var(--line);border-radius:18px;padding:17px;box-shadow:0 10px 28px rgba(15,23,42,.06)}.adminStatCard span{display:block;color:#64748b;font-size:12px;font-weight:850;text-transform:uppercase;letter-spacing:.06em}.adminStatCard b{display:block;font-size:30px;margin:8px 0 4px;color:#0f172a}.adminStatCard small{color:#64748b}.userAdminCard{border-color:#c7d2fe!important;background:linear-gradient(180deg,#fff,#f8faff)}.addUserGrid{grid-template-columns:1.2fr 1fr .8fr auto;align-items:end}.adminUsersList{display:grid;gap:9px;margin-top:14px}.adminUserRow{display:grid;grid-template-columns:1fr auto auto;gap:10px;align-items:center;padding:12px 13px;border:1px solid #e2e8f0;border-radius:14px;background:#fff}.adminUserRow b,.adminUserRow small{display:block}.adminUserRow small{margin-top:3px;color:#64748b}.userPill,.lockPill{display:inline-flex;align-items:center;justify-content:center;border-radius:999px;padding:7px 10px;font-size:11px;font-weight:900;white-space:nowrap}.userPill.user{background:#eff6ff;color:#1d4ed8}.userPill.master{background:#fef3c7;color:#92400e}.userPill.super{background:#fce7f3;color:#be185d}.lockPill{background:#f1f5f9;color:#475569}.emptyState{padding:16px;border:1px dashed #cbd5e1;border-radius:14px;background:#f8fafc;color:#64748b;text-align:center}
@media(max-width:1000px){.adminDashboardGrid{grid-template-columns:repeat(2,minmax(0,1fr))}.addUserGrid{grid-template-columns:1fr 1fr}.adminUserRow{grid-template-columns:1fr;align-items:start}}
@media(max-width:640px){.adminDashboardGrid,.addUserGrid{grid-template-columns:1fr}}

/* v22 letterpad hard fix: stable preview, 3 templates, logo always visible */
.letterTemplateGallery{grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:12px!important;margin-top:10px!important}
.letterTemplateBtn{display:grid!important;grid-template-rows:auto auto auto;gap:7px!important;border:1px solid #dbe2ea!important;background:#fff!important;border-radius:16px!important;padding:10px!important;text-align:left!important;cursor:pointer!important;box-shadow:0 6px 18px rgba(15,23,42,.05)!important}
.letterTemplateBtn.active{border-color:#2563eb!important;box-shadow:0 0 0 2px #dbeafe,0 10px 24px rgba(37,99,235,.12)!important;background:#f8fbff!important}
.letterMini{height:82px;border:1px solid #e2e8f0;border-radius:12px;background:#fff;display:block;position:relative;overflow:hidden;padding:10px}.letterMini img{width:70px;height:auto;display:block}.letterMini i{position:absolute;left:10px;right:10px;bottom:14px;height:1px;background:#0f172a}.letterMini em{position:absolute;left:10px;right:10px;bottom:8px;height:2px;background:#e5e7eb}.letterMini-topAddress img{width:58px}.letterMini-topAddress:after{content:"";position:absolute;right:10px;top:12px;width:64px;height:28px;border-radius:4px;background:#eef2ff}.letterMini-modern{background:linear-gradient(180deg,#fff,#f8fafc)}.letterMini-modern i{background:#94a3b8}.letterMini-modern img{width:82px}
.letterPreview.properLetter{width:min(100%,595px)!important;min-height:842px!important;aspect-ratio:210/297!important;background:#fff!important;color:#0f172a!important;border:1px solid #e5e7eb!important;border-radius:4px!important;box-shadow:0 12px 34px rgba(15,23,42,.15)!important;overflow:hidden!important;display:block!important;margin:0 auto!important}
.letterPreview.properLetter .lpPage{width:100%!important;height:100%!important;min-height:842px!important;padding:48px 56px 108px!important;position:relative!important;background:#fff!important;overflow:hidden!important;box-sizing:border-box!important}
.letterPreview.properLetter .lpHeader{display:flex!important;justify-content:space-between!important;align-items:flex-start!important;gap:36px!important;min-height:98px!important}
.letterPreview.properLetter .lpLogo{width:190px!important;max-width:42%!important;height:auto!important;display:block!important;object-fit:contain!important;margin:0!important;visibility:visible!important;opacity:1!important}
.letterPreview.properLetter .lpHeaderRight{max-width:270px!important;text-align:left!important;margin-top:2px!important}.letterPreview.properLetter .lpContact{font-size:11px!important;line-height:1.55!important;font-weight:750!important;white-space:nowrap!important;color:#0f172a!important}.letterPreview.properLetter .lpTopAddress{font-size:9px!important;line-height:1.35!important;margin-top:8px!important;color:#334155!important}.letterPreview.properLetter .lpBelowAddress{margin:12px 0 0!important}
.letterPreview.properLetter .lpRule{height:1px!important;background:#111827!important;margin-top:22px!important}.letterPreview.properLetter .lpMain{font-size:12px!important;line-height:1.56!important;margin-top:28px!important;color:#111827!important}.letterPreview.properLetter .lpDate{text-align:right!important;margin-bottom:20px!important}.letterPreview.properLetter .lpRecipient{margin-bottom:20px!important}.letterPreview.properLetter .lpSubject{display:block!important;border:0!important;text-decoration:none!important;margin:14px 0 20px!important;font-weight:750!important;min-height:0!important}.letterPreview.properLetter .lpSubject:before,.letterPreview.properLetter .lpSubject:after{display:none!important}.letterPreview.properLetter .lpSubject span:first-of-type{border:0!important;min-width:0!important;min-height:0!important}.letterPreview.properLetter .lpCase{margin-left:12px!important;font-size:10px!important;color:#475569!important;font-weight:650!important}.letterPreview.properLetter .lpSalutation{margin-bottom:18px!important}.letterPreview.properLetter .lpBody{min-height:210px!important;max-height:310px!important;overflow:hidden!important;white-space:normal!important}.letterPreview.properLetter .lpSignBlock{margin-top:22px!important;margin-bottom:78px!important;line-height:1.45!important;max-width:310px!important;clear:both!important}.letterPreview.properLetter .lpSign-center{text-align:center!important;margin-left:auto!important;margin-right:auto!important}.letterPreview.properLetter .lpSign-right{text-align:right!important;margin-left:auto!important}.letterPreview.properLetter .lpClose{margin:0 0 10px!important}.letterPreview.properLetter .letterSig{max-width:160px!important;max-height:52px!important;display:block!important;margin:0 0 7px!important}.letterPreview.properLetter .lpSign-center .letterSig{margin-left:auto!important;margin-right:auto!important}.letterPreview.properLetter .lpSign-right .letterSig{margin-left:auto!important}.letterPreview.properLetter .lpSigner{line-height:1.42!important}.letterPreview.properLetter .lpRole{font-weight:400!important;color:#334155!important}.letterPreview.properLetter .lpFooter{position:absolute!important;left:56px!important;right:56px!important;bottom:32px!important;text-align:center!important;border-top:1px solid #111827!important;padding-top:11px!important;font-size:9px!important;line-height:1.38!important;background:#fff!important;z-index:2!important}.letterPreview.properLetter .lpTemplate-modern .lpRule{background:#94a3b8!important}.letterPreview.properLetter .lpTemplate-modern .lpFooter{border-top-color:#94a3b8!important}.letterPreview.properLetter .lpTemplate-topAddress .lpHeaderRight{max-width:310px!important}.letterError{padding:18px;border:1px solid #fecaca;background:#fef2f2;color:#991b1b;border-radius:12px;margin:20px;font-weight:800}
@media(max-width:900px){.letterTemplateGallery{grid-template-columns:1fr!important}.letterPreview.properLetter{min-height:720px!important}.letterPreview.properLetter .lpPage{min-height:720px!important;padding:34px 34px 92px!important}.letterPreview.properLetter .lpFooter{left:34px!important;right:34px!important}.letterPreview.properLetter .lpHeader{gap:18px!important}.letterPreview.properLetter .lpLogo{width:150px!important}.letterPreview.properLetter .lpContact{font-size:10px!important}}

/* v23 direct browser print preview */
.pdfOutputMode{font-weight:800;background:#f0fdf4;border-color:#86efac}.printCentreCard .toolbar .primary{background:linear-gradient(135deg,#16a34a,#15803d)}
.scanFastToggle{display:flex;align-items:center;gap:8px;margin-top:12px;padding:10px 12px;border:1px solid var(--line);border-radius:14px;background:#f8fafc;font-size:12px;font-weight:800;color:#334155}.scanFastToggle input{width:auto;margin:0}
