/* The mill (المطحنة): its own look, fonts served from here so the pages also work without internet. */
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:400;font-display:swap;src:url(../fonts/mill/ibm-plex-sans-arabic-arabic-400-normal.woff2) format('woff2');unicode-range:U+0600-06FF,U+0750-077F,U+0870-088E,U+0890-0891,U+0897-08E1,U+08E3-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FE74,U+FE76-FEFC}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:400;font-display:swap;src:url(../fonts/mill/ibm-plex-sans-arabic-latin-400-normal.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:500;font-display:swap;src:url(../fonts/mill/ibm-plex-sans-arabic-arabic-500-normal.woff2) format('woff2');unicode-range:U+0600-06FF,U+0750-077F,U+0870-088E,U+0890-0891,U+0897-08E1,U+08E3-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FE74,U+FE76-FEFC}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:500;font-display:swap;src:url(../fonts/mill/ibm-plex-sans-arabic-latin-500-normal.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:600;font-display:swap;src:url(../fonts/mill/ibm-plex-sans-arabic-arabic-600-normal.woff2) format('woff2');unicode-range:U+0600-06FF,U+0750-077F,U+0870-088E,U+0890-0891,U+0897-08E1,U+08E3-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FE74,U+FE76-FEFC}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:600;font-display:swap;src:url(../fonts/mill/ibm-plex-sans-arabic-latin-600-normal.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:700;font-display:swap;src:url(../fonts/mill/ibm-plex-sans-arabic-arabic-700-normal.woff2) format('woff2');unicode-range:U+0600-06FF,U+0750-077F,U+0870-088E,U+0890-0891,U+0897-08E1,U+08E3-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FE74,U+FE76-FEFC}
@font-face{font-family:'IBM Plex Sans Arabic';font-style:normal;font-weight:700;font-display:swap;src:url(../fonts/mill/ibm-plex-sans-arabic-latin-700-normal.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:500;font-display:swap;src:url(../fonts/mill/ibm-plex-mono-latin-500-normal.woff2) format('woff2')}
@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:600;font-display:swap;src:url(../fonts/mill/ibm-plex-mono-latin-600-normal.woff2) format('woff2')}

:root{--ink:#13211d;--mut:#5c6e68;--bg:#f2f6f4;--card:#fff;--line:#dde6e2;--line2:#cbd8d3;--a:#12997d;--a2:#0b7a63;--a3:#0a4f41;--soft:#e2f4ef;--nav:#eaf2ef;
  --warn:#8a5a00;--warn-bg:#fdf0d2;--bad:#b3261e;--bad-bg:#fde7e9;
  --f:'IBM Plex Sans Arabic','Segoe UI',Tahoma,sans-serif;--fn:'IBM Plex Mono',ui-monospace,Menlo,monospace;
  --r:16px;--sh1:0 1px 2px rgba(16,40,33,.06),0 1px 1px rgba(16,40,33,.04);--sh2:0 10px 30px rgba(16,40,33,.16)}
*{box-sizing:border-box;-webkit-tap-highlight-color:transparent}
html{-webkit-text-size-adjust:100%}
body{margin:0;font-family:var(--f);color:var(--ink);background:var(--bg);font-size:15.5px;line-height:1.5;min-height:100vh;display:flex;flex-direction:column}
a{color:var(--a2);text-decoration:none}a:hover{color:var(--a3)}
h1,h2,h3,p{margin:0}
h1{font-size:18px;font-weight:700}h2{font-size:17px;font-weight:700}
button{cursor:pointer;font-family:inherit}
:focus-visible{outline:3px solid #8ad8c6;outline-offset:2px}
body:focus-visible{outline:0}
.n{font-family:var(--fn);font-weight:500;direction:ltr;unicode-bidi:isolate;font-variant-numeric:tabular-nums}
b.n,b .n,.n b,h1 .n,h2 .n,.btn .n{font-weight:600}
.mut{color:var(--mut)}.sm{font-size:13px}
svg.mi{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.75;stroke-linecap:round;stroke-linejoin:round;flex:none}
.card{background:var(--card);border-radius:var(--r);padding:16px;box-shadow:var(--sh1)}
.pill{border:0;box-shadow:inset 0 0 0 1.5px var(--line);background:#fff;border-radius:13px;min-height:48px;padding:0 16px;font:500 15.5px var(--f);color:var(--ink);display:inline-flex;align-items:center;gap:6px;transition:transform .08s}
.pill:active{transform:scale(.96)}
.on,.pill:has(input:checked){background:var(--soft);box-shadow:inset 0 0 0 1.5px var(--a);color:var(--a3);font-weight:600}
.pill input{position:absolute;opacity:0;width:0;height:0}
.pill:has(input:focus-visible){outline:3px solid #8ad8c6;outline-offset:2px}
.btn{border:0;border-radius:15px;min-height:52px;padding:0 18px;font:700 16px var(--f);background:var(--a);color:#fff;display:inline-flex;align-items:center;justify-content:center;gap:8px;transition:transform .1s,background .12s}
.btn:hover{background:var(--a2);color:#fff}.btn:active{transform:scale(.98)}
.sec{background:#fff;color:var(--a3);box-shadow:inset 0 0 0 1.5px var(--line)}.sec:hover{background:#f4f8f6;color:var(--a3)}
.x{border:0;background:none;color:var(--bad);min-width:44px;min-height:44px;border-radius:12px;font-size:20px;line-height:1}.x:hover{background:var(--bad-bg)}
.tag{display:inline-flex;align-items:center;gap:6px;border-radius:999px;padding:3px 11px;font-size:13px;font-weight:600;white-space:nowrap}
.ok{background:var(--soft);color:var(--a3)}.due{background:var(--bad-bg);color:var(--bad)}.wait{background:var(--warn-bg);color:var(--warn)}.off{background:#e9efec;color:#44544f}
.tab{padding:0 14px;border-radius:11px;color:var(--mut);font-weight:500;min-height:42px;display:inline-flex;align-items:center;gap:8px}
.tab:hover{color:var(--a3)}
.tab.cur{background:var(--soft);color:var(--a3);font-weight:600}
.row{display:flex;align-items:center;gap:10px;padding:10px 0;border-bottom:1px solid #edf2ef}.row:last-of-type{border-bottom:0}
input[type=text],input[type=password],input[type=tel],input[type=search],input[type=number],input:not([type]),select,textarea{font:inherit;border:1.5px solid var(--line);border-radius:14px;min-height:50px;padding:0 14px;background:#fff;color:var(--ink);width:100%}
input:focus,select:focus,textarea:focus{border-color:var(--a);outline:0;box-shadow:0 0 0 3px #d5f1ea}
.fld{flex:1 1 150px;min-width:0;display:flex;flex-direction:column;gap:5px}.fld label{font-size:13.5px;color:var(--mut);font-weight:500}
.flex{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.col{display:flex;flex-direction:column;gap:12px}
.msg{border-radius:13px;padding:10px 14px;font-weight:600}.msg.good{background:var(--soft);color:var(--a3)}.msg.bad{background:var(--bad-bg);color:var(--bad)}

/* frame: header on top, the screens as tabs (computer) or as a dock at the bottom (phone) */
.top{display:flex;align-items:center;gap:14px;background:var(--card);border-bottom:1px solid var(--line);padding:0 16px;min-height:60px;position:sticky;top:0;z-index:15}
.logo{font-size:17px;font-weight:700;display:flex;align-items:center;gap:10px;color:var(--ink);white-space:nowrap}
.logo img{width:38px;height:38px;flex:none;display:block}.login .logo img{width:72px;height:72px}
.logo i{width:38px;height:38px;border-radius:11px;background:var(--a);color:#fff;display:grid;place-items:center}
.mainnav{display:flex;gap:4px;margin-inline-start:8px}
.side{margin-inline-start:auto;display:flex;gap:8px;align-items:center}
.side .tag{min-height:30px}.side .drawer{gap:0}
.side form{margin:0}.side button{border:0;background:#eef3f0;color:#3d4d48;width:40px;height:40px;border-radius:12px;display:grid;place-items:center}
.side button:hover{background:var(--bad-bg);color:var(--bad)}
#net::before{content:'';width:8px;height:8px;border-radius:50%;background:currentColor;flex:none}
main{padding:14px 16px 24px;display:flex;flex-direction:column;gap:14px;flex:1}
.cols{display:flex;flex-wrap:wrap;gap:14px;align-items:flex-start}.cols>section{flex:1 1 340px;min-width:0;display:flex;flex-direction:column;gap:14px}
.subtabs{display:flex;gap:6px;flex-wrap:wrap;align-items:center}
.subtabs .tab{background:var(--card);box-shadow:inset 0 0 0 1.5px var(--line);border-radius:999px;min-height:42px;padding:0 16px;color:var(--ink)}
.subtabs .tab.cur{background:var(--a3);color:#fff;box-shadow:none}
.dock{display:none}
@media (max-width:900px){
  .top{padding:0 12px;gap:8px}.mainnav{display:none}
  main{padding:12px 12px 88px}
  .subtabs{flex-wrap:nowrap;overflow-x:auto;margin-inline:-12px;padding:0 12px 2px;scrollbar-width:none}.subtabs::-webkit-scrollbar{display:none}.subtabs .tab{flex:none}
  .dock{display:flex;position:fixed;inset-inline:0;bottom:0;background:var(--card);border-top:1px solid var(--line);padding:4px 4px max(4px,env(safe-area-inset-bottom));z-index:20}
  .dock a{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;min-height:54px;font-size:12px;font-weight:500;color:var(--mut);border-radius:12px}
  .dock a i{display:grid;place-items:center;height:26px}
  .dock a.cur{font-weight:600;color:var(--a3)}.dock a.cur svg{stroke-width:2.1}
  .side .who{display:none}
}
@media (max-width:520px){
  #net{font-size:0;gap:0;padding:0 11px}
  #net.wait,#net.due{font-size:12px;gap:6px;max-width:150px;overflow:hidden;text-overflow:ellipsis}
  .side .drawer .lg{display:none}
}

/* sheets: a panel from the bottom (phone) or in the middle (computer). One at a time, stacked. */
#mscrim{position:fixed;inset:0;background:rgba(12,28,23,.42);opacity:0;pointer-events:none;transition:opacity .2s;z-index:40}
#mscrim.on{opacity:1;pointer-events:auto}
#msheet{position:fixed;inset-inline:0;bottom:0;max-height:92%;background:var(--card);border-radius:22px 22px 0 0;z-index:41;transform:translateY(105%);transition:transform .24s cubic-bezier(.2,.8,.2,1);display:flex;flex-direction:column;box-shadow:var(--sh2)}
#msheet.on{transform:none}
#msheet .grab{width:42px;height:5px;border-radius:3px;background:#cfdad5;margin:8px auto 0;flex:none}
#msheet-body{flex:1;min-height:0;overflow-y:auto;display:flex;flex-direction:column}
.sh-head{display:flex;align-items:center;gap:10px;padding:10px 16px 6px}
.sh-x{margin-inline-start:auto;width:40px;height:40px;border-radius:12px;border:0;display:grid;place-items:center;color:var(--mut);background:#eef3f0;flex:none}
.sh-pad{padding:4px 16px 16px;display:flex;flex-direction:column;gap:10px}
@media (min-width:901px){
  #msheet{inset-inline:0;margin-inline:auto;bottom:auto;top:50%;width:420px;max-height:calc(100% - 40px);border-radius:22px;transform:translateY(-46%) scale(.97);opacity:0;pointer-events:none;transition:transform .18s,opacity .18s}
  #msheet.on{transform:translateY(-50%);opacity:1;pointer-events:auto}
  #msheet .grab{display:none}.sh-head{padding-top:16px}
}
/* the number pad: big keys, quick amounts */
.np-seg{display:flex;background:#eaf0ed;border-radius:13px;padding:4px;gap:4px}
.np-seg button{flex:1;border:0;background:none;min-height:42px;border-radius:10px;font-weight:500;color:var(--mut)}
.np-seg button.cur{background:#fff;color:var(--a3);font-weight:600;box-shadow:var(--sh1)}
.np-disp{display:flex;justify-content:space-between;align-items:center;gap:10px;background:#f1f5f3;border-radius:16px;padding:10px 16px;min-height:72px}
.np-disp .v{font-size:38px;font-weight:600;line-height:1.1}.np-disp .v.zero{color:#9fb0aa}
.np-err{color:var(--bad);font-weight:600;font-size:14px}.np-err:empty{display:none}
.np-quick{display:flex;gap:6px;direction:ltr}
.np-quick button{flex:1;min-width:0;min-height:48px;border:0;font:500 16px var(--fn);border-radius:12px;background:var(--soft);color:var(--a3)}
.np-quick button:active,.np-key:active{transform:scale(.95)}
.np-keys{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;direction:ltr}
.np-key{min-height:58px;border:0;border-radius:15px;background:var(--card);box-shadow:inset 0 0 0 1.5px var(--line);font:600 23px var(--fn);color:var(--ink);display:grid;place-items:center;transition:transform .08s}
.np-key.fn{background:#eef3f0;box-shadow:none;color:#3d4d48}
.bump{animation:bump .28s}@keyframes bump{40%{transform:scale(1.06)}}
@media (prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}}
/* login */
.login{flex:1;display:grid;place-items:center;padding:24px 16px}
.login form{width:100%;max-width:380px;display:flex;flex-direction:column;gap:12px}
.login .logo{flex-direction:column;font-size:22px;margin-bottom:6px}.login .logo i{width:64px;height:64px;border-radius:20px}
.col>.fld,.login .fld{flex:none}
/* screens */
.grow{flex:1;min-width:0}
.sum{display:flex;justify-content:space-between;align-items:center;font-size:18px;font-weight:700;padding-top:6px}
.stat{flex:1 1 120px}.stat b{font-size:22px;display:block}
.inv{display:flex;align-items:center;gap:10px;padding:12px 0;border-bottom:1px solid #edf2ef;flex-wrap:wrap}.inv:last-child{border-bottom:0}
.inv .no{font-weight:700;min-width:44px}
.acts{display:flex;gap:6px;flex-wrap:wrap;width:100%}
.mini{border:0;box-shadow:inset 0 0 0 1.5px var(--line);background:#fff;border-radius:11px;min-height:42px;padding:0 13px;font:500 14px var(--f);color:var(--ink);display:inline-flex;align-items:center;gap:6px}
.mini:hover{background:#f4f8f6}.mini.go{background:var(--a);box-shadow:none;color:#fff;font-weight:600}.mini.bad{color:var(--bad)}
.filters{display:flex;gap:6px;flex-wrap:wrap}.filters button{border:0;cursor:pointer;min-height:40px;padding:2px 16px}
button:disabled{opacity:.55;cursor:default}
.flash{position:fixed;inset-inline:16px;top:72px;margin:auto;max-width:460px;z-index:60;border-radius:14px;padding:12px 16px;font-weight:600;box-shadow:var(--sh2);text-align:center;animation:drop .22s cubic-bezier(.2,.8,.2,1)}
@keyframes drop{from{transform:translateY(-14px);opacity:0}}
.flash.good{background:var(--ink);color:#fff}.flash.bad{background:var(--bad);color:#fff}
dialog{border:0;border-radius:22px;padding:18px;box-shadow:var(--sh2);width:min(420px,calc(100vw - 32px));color:var(--ink);font-family:inherit}
dialog::backdrop{background:rgba(12,28,23,.42)}
dialog form{display:flex;flex-direction:column;gap:12px}
.pick{cursor:pointer}.pick:hover{background:#f6faf9}
.pick.cur{background:var(--soft);border-radius:10px}
#cam{width:100%;border-radius:12px;background:#000;max-height:240px}
[hidden]{display:none!important}
@media (max-width:900px){.inv .grow{flex:1 1 60%}}
/* shop: products and the till */
.pgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(118px,1fr));gap:8px}
.ptile{border:0;box-shadow:var(--sh1);background:#fff;border-radius:16px;padding:8px;display:flex;flex-direction:column;gap:4px;text-align:start;font:inherit;color:var(--ink);min-height:44px}
.ptile:hover{box-shadow:var(--sh1),inset 0 0 0 1.5px var(--a)}.ptile:active{transform:scale(.97)}
.ptile b{font-weight:600;font-size:13.5px;line-height:1.3;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.pic{aspect-ratio:1;border-radius:10px;background:var(--nav);display:grid;place-items:center;overflow:hidden;color:var(--a3);font-size:26px;font-weight:700}
.pic img{width:100%;height:100%;object-fit:cover;display:block}
.thumb{width:48px;height:48px;border-radius:10px;flex:none;font-size:18px}
.chips{display:flex;gap:6px;overflow-x:auto;padding-bottom:2px;scrollbar-width:none}.chips button{flex:none;border:0;min-height:40px;padding:2px 16px}
.qty{width:84px!important;min-height:40px!important;text-align:center;padding:0 6px!important}
.banner{border-radius:14px;padding:10px 14px;background:var(--warn-bg);color:var(--warn);display:flex;gap:10px;align-items:center;flex-wrap:wrap;font-weight:600}
dialog.wide{width:min(560px,calc(100vw - 24px));max-height:calc(100vh - 24px);overflow:auto}
/* office: numbers, expenses, cheques */
.dock a{position:relative}.badge{position:absolute;top:0;inset-inline-start:50%;margin-inline-start:10px;padding:0 6px;font-size:11px}
.kpis{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:10px}
.kpi{background:#fff;box-shadow:var(--sh1);border-radius:16px;padding:14px}.kpi b{font-size:22px;display:block}
.up{color:var(--a2)}.down{color:var(--bad)}
.bars{display:flex;align-items:flex-end;gap:2px;height:120px;direction:ltr}
.bars>span{flex:1;min-width:2px;background:var(--a);border-radius:3px 3px 0 0;position:relative}.bars>span i{position:absolute;inset-inline:0;bottom:0;background:#e8b84a;border-radius:3px 3px 0 0}
.bars.two>span{background:none;display:flex;gap:1px;align-items:flex-end}.bars.two>span u{flex:1;background:var(--a);border-radius:3px 3px 0 0}.bars.two>span u+u{background:#d0667c}
.hbar{height:8px;border-radius:4px;background:var(--nav);overflow:hidden}.hbar i{display:block;height:100%;background:var(--a)}
input[type=date]{font:inherit;border:1.5px solid var(--line);border-radius:14px;min-height:50px;padding:0 10px;background:#fff;color:var(--ink);font-family:var(--fn)}
/* the sale screen: products fill the page; the basket is a side column (computer) or a floating bar + sheet (phone) */
.pos{flex-direction:row;align-items:flex-start;gap:16px}
.pos-main{flex:1;min-width:0;display:flex;flex-direction:column;gap:12px}
.pos-side{display:none}
.tools{display:flex;gap:8px;align-items:center}
.search{flex:1;min-width:0;height:50px;background:var(--card);border:1.5px solid var(--line);border-radius:14px;display:flex;align-items:center;gap:8px;padding:0 12px;color:var(--mut)}
.search:focus-within{border-color:var(--a);box-shadow:0 0 0 3px #d5f1ea}
.search input{flex:1;min-width:0;border:0!important;outline:0;background:none;font:inherit;color:var(--ink);height:100%;min-height:0;padding:0;box-shadow:none!important}
.sq{width:50px;height:50px;border-radius:14px;background:var(--card);border:1.5px solid var(--line);display:grid;place-items:center;color:var(--a3);flex:none}
.cats{display:flex;gap:8px;overflow-x:auto;padding:12px 0 4px;scrollbar-width:none}.cats::-webkit-scrollbar{display:none}.cats:empty{display:none}
.cats button{height:40px;padding:0 16px;border-radius:999px;background:var(--card);border:1.5px solid var(--line);white-space:nowrap;font-weight:500;color:#3d4d48;flex:none}
.cats button.cur{background:var(--a3);border-color:var(--a3);color:#fff}
.hint{display:flex;align-items:center;gap:8px;margin-top:8px;padding:8px 12px;border-radius:12px;background:var(--soft);color:var(--a3);font-size:13.5px}
.hint button{margin-inline-start:auto;border:0;background:none;color:inherit;width:32px;height:32px;border-radius:8px;display:grid;place-items:center;flex:none}
.pcs{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:10px;margin-top:10px}
.pc{position:relative;border:0;background:var(--card);border-radius:var(--r);box-shadow:var(--sh1);padding:8px 8px 10px;text-align:start;display:flex;flex-direction:column;gap:6px;font:inherit;color:var(--ink);touch-action:pan-y;user-select:none;-webkit-user-select:none;-webkit-touch-callout:none;transition:transform .12s,box-shadow .15s}
.pc:active{transform:scale(.97)}.pc.out{opacity:.6}
.pc.lift{z-index:5;box-shadow:var(--sh2);transition:none;cursor:grabbing}
.pc .art{height:92px;border-radius:12px;display:grid;place-items:center;background:var(--soft);color:var(--a2);font-size:30px;font-weight:700;overflow:hidden}
.pc .art img{width:100%;height:100%;object-fit:cover;display:block;pointer-events:none}
.pc b{font-weight:600;line-height:1.3;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;min-height:2.6em}
.pc .pr{display:flex;align-items:baseline;gap:4px}.pc .pr .n{font-size:17px;font-weight:600;color:var(--a3)}
.pc .stk{position:absolute;top:14px;inset-inline-start:14px;height:24px;padding:0 8px;border-radius:999px;background:rgba(255,255,255,.92);font-size:12px;font-weight:600;display:flex;align-items:center;gap:3px;color:#3d4d48}
.pc .stk.low{background:var(--warn-bg);color:var(--warn)}.pc .stk.zero{background:var(--bad-bg);color:var(--bad)}
.pc .add{position:absolute;bottom:10px;inset-inline-end:10px;width:36px;height:36px;border-radius:11px;background:var(--a3);color:#fff;display:grid;place-items:center}
.pc .qb{position:absolute;top:-6px;left:-6px;min-width:26px;height:26px;padding:0 7px;border-radius:999px;background:var(--a);color:#fff;font-size:13px;font-weight:600;display:grid;place-items:center;box-shadow:0 0 0 3px #fff}
.pk-tag{align-self:flex-start;font-size:12.5px;padding:2px 8px;border-radius:999px;background:#fff5dc;color:#7a5600}
.packs{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.pack{display:grid;gap:2px;justify-items:start;text-align:start;padding:12px;min-height:96px;border-radius:14px;background:#f0faf7;border:1.5px solid var(--a);font:inherit;color:var(--ink)}
.pack b{font-size:17px}.pack .pp{font-size:19px;font-weight:700;color:var(--a3)}.pack:active{transform:scale(.97)}
.or{text-align:center;font-size:13px;color:var(--mut)}
.fly{position:fixed;z-index:70;width:28px;height:28px;border-radius:50%;background:var(--a);pointer-events:none;box-shadow:var(--sh2)}
/* the basket */
.cart{display:flex;flex-direction:column;min-height:0;flex:1}
.cart-head{display:flex;align-items:center;gap:8px;padding:14px 16px 8px}
.cart .lines{flex:1;min-height:60px;overflow-y:auto;padding:0 8px}
.ln{display:flex;align-items:center;gap:6px}
.ln-b{flex:1;min-width:0;display:flex;align-items:center;gap:10px;padding:8px;border:0;background:none;border-radius:12px;text-align:start;font:inherit;color:var(--ink)}
.ln-b:hover{background:#f4f8f6}
.ln-b .g{flex:1;min-width:0}.ln-b .g b{display:block;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.ln-b .t{font-weight:600;font-size:16px}
.rm{width:40px;height:40px;border:0;background:none;border-radius:10px;display:grid;place-items:center;color:var(--mut);flex:none}.rm:hover{background:var(--bad-bg);color:var(--bad)}
.empty{display:grid;place-items:center;gap:6px;padding:34px 16px;color:var(--mut);text-align:center}
.cart .foot{border-top:1px dashed var(--line);padding:12px 16px 16px;display:flex;flex-direction:column;gap:6px}
.rw{display:flex;justify-content:space-between;align-items:baseline;gap:10px}
.cart .total{font-size:17px;font-weight:700}.cart .total>span:last-child>.n{font-size:30px;font-weight:600;color:var(--a3)}
.link{border:0;background:none;padding:0;color:var(--a2);font:600 15px var(--f);text-decoration:underline;text-underline-offset:3px;min-height:36px}
.btns{display:flex;gap:8px;margin-top:6px}
.cartbar{position:fixed;inset-inline:12px;bottom:calc(68px + env(safe-area-inset-bottom));z-index:19;height:60px;border:0;border-radius:18px;background:var(--a3);color:#fff;display:flex;align-items:center;gap:12px;padding:0 14px 0 8px;box-shadow:var(--sh2);font:inherit}
.cartbar .cnt{min-width:28px;height:28px;border-radius:999px;background:#fff;color:var(--a3);display:grid;place-items:center;font-weight:600;font-size:14px;padding:0 6px}
.cartbar .tot{font-size:20px;font-weight:600}
.cartbar .go{margin-inline-start:auto;height:44px;padding:0 16px;border-radius:13px;background:rgba(255,255,255,.16);display:flex;align-items:center;gap:6px;font-weight:600}
.done{display:grid;place-items:center;gap:8px;padding:26px 16px 8px;text-align:center}
.done .okc{width:72px;height:72px;border-radius:50%;background:var(--soft);color:var(--a2);display:grid;place-items:center}
.done .big{font-size:34px;font-weight:600;color:var(--a3)}
.sug{display:flex;flex-wrap:wrap;gap:8px}.sug button{border:0;min-height:42px;padding:0 14px;border-radius:999px;background:#eef3f0;color:var(--ink);font:inherit}
@media (max-width:900px){.pos{padding-bottom:156px}}
@media (min-width:901px){
  .pos-side{display:flex;flex-direction:column;width:400px;flex:none;background:var(--card);border-radius:var(--r);box-shadow:var(--sh1);position:sticky;top:74px;height:calc(100vh - 88px);min-height:0}
  .cartbar{display:none!important}
  .pcs{grid-template-columns:repeat(auto-fill,minmax(168px,1fr));gap:12px}.pc .art{height:108px}
}
.sq.on{background:var(--a3);border-color:var(--a3);color:#fff}
/* milling: big buttons for the grain and the flour */
.bigs{display:grid;grid-template-columns:repeat(auto-fill,minmax(140px,1fr));gap:10px}
.big{position:relative;border:0;background:var(--card);box-shadow:var(--sh1);border-radius:var(--r);min-height:84px;padding:12px 14px;display:flex;flex-direction:column;justify-content:center;gap:2px;text-align:start;font:inherit;color:var(--ink);transition:transform .1s}
.big:active{transform:scale(.97)}
.big b{font-size:17px;font-weight:600}
.big.on{background:var(--soft);box-shadow:inset 0 0 0 2px var(--a);color:var(--a3)}
.big .mi{color:var(--a2)}
.big .add{position:absolute;inset-block:0;margin:auto 0;inset-inline-end:12px;width:36px;height:36px;border-radius:11px;background:var(--a3);color:#fff;display:grid;place-items:center}
.big .add .mi{color:#fff}
.stepper{display:flex;align-items:center;gap:10px}
.stepper button{width:44px;height:44px;border:0;border-radius:12px;background:#eef3f0;font:600 20px var(--fn);color:var(--ink)}
.stepper b{min-width:26px;text-align:center}
/* stock and customers: a list to tap, one panel per product or customer */
@media (max-width:900px){.pos.plain{padding-bottom:96px}
  .fab{position:fixed;inset-inline-end:14px;bottom:calc(78px + env(safe-area-inset-bottom));width:58px;height:58px;border-radius:19px;background:var(--a3);border-color:var(--a3);color:#fff;box-shadow:var(--sh2);z-index:19}
  .fab.on{background:var(--bad);border-color:var(--bad)}}
.pos-side[hidden]{display:none!important}
.pos-side{overflow-y:auto}
.alertb{border:0;width:100%;font:600 15px var(--f);text-align:start;cursor:pointer}
.srows{padding:4px}
.srow{width:100%;display:flex;align-items:center;gap:12px;padding:10px 12px;border:0;border-bottom:1px solid #edf2ef;background:none;text-align:start;font:inherit;color:var(--ink);border-radius:12px;min-height:68px}
.srow:last-child{border-bottom:0}.srow:hover{background:#f4f8f6}.srow.cur{background:var(--soft)}
.srow .g{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}.srow .g b{font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.srow .amt{font-weight:600;font-size:16px;white-space:nowrap}.srow .amt.owe{color:var(--bad)}
.av{flex:none;width:44px;height:44px;border-radius:14px;display:grid;place-items:center;background:var(--soft);color:var(--a3);font-weight:700;font-size:18px}.av.big{width:64px;height:64px;font-size:26px;border-radius:18px}
.pp{padding:4px 16px 18px;display:flex;flex-direction:column;gap:12px}
.pp h3{font-size:15px;font-weight:600;margin:4px 0 -4px}
.pp-top{display:flex;align-items:center;gap:14px}.pp-top .pic{width:84px;flex:none;font-size:30px;border-radius:16px}
.pp-n{font-size:19px;font-weight:600;line-height:1.2;margin-bottom:4px}.pp-n .n{font-size:38px;color:var(--a3)}
.acts4{display:grid;grid-template-columns:repeat(4,1fr);gap:8px}
.acts4 button{border:0;border-radius:14px;min-height:72px;background:#eef3f0;color:var(--ink);font:600 14.5px var(--f);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;transition:transform .1s}
.acts4 button:active{transform:scale(.96)}.acts4 button.go{background:var(--a);color:#fff}.acts4 button:disabled{opacity:.45}
.facts{border-radius:14px;background:#f6f9f7;padding:4px 14px}
.facts>div{display:flex;justify-content:space-between;gap:10px;padding:9px 0;border-bottom:1px solid #e6ede9}.facts>div:last-child{border-bottom:0}
.facts span{color:var(--mut)}.facts b{font-weight:600;color:var(--ink)}.facts b .n,.facts span .n{color:inherit}
.mv{display:flex;align-items:center;gap:10px;padding:9px 0;border-bottom:1px solid #edf2ef}.mv:last-child{border-bottom:0}
.mv .g{flex:1;min-width:0;display:flex;flex-direction:column}.mv .aft{min-width:52px;text-align:end}
.ptop{display:flex;flex-direction:column;gap:6px}
.np-quick.why{flex-wrap:wrap}.np-quick.why button{flex:1 1 auto}.np-quick.why button.cur{background:var(--a3);color:#fff;border-color:var(--a3);box-shadow:none}
.kpis.in .kpi{box-shadow:none;background:#f4f8f6}
.np-quick.why{direction:rtl}.np-quick.why button{font:500 15px var(--f);padding:0 12px}
.alertb .link{display:inline-flex;align-items:center}
@media (max-width:520px){.kpis>.kpi:last-child:nth-child(odd){grid-column:1/-1}}
/* management */
.subtabs button.tab{border:0;font:inherit;cursor:pointer}
.kpi b{font-weight:600}.kpi b .n{font-weight:600}
/* the till's bar of names: who is recording */
.ops{display:flex;align-items:center;gap:8px;overflow-x:auto;padding:10px 0 2px;scrollbar-width:none}.ops::-webkit-scrollbar{display:none}.ops[hidden]{display:none}
.ops-l{flex:none;font-size:13px;color:var(--mut);font-weight:500}
.ops.ask .ops-l{color:#8a5a00;background:#fff3d6;border-radius:999px;padding:6px 12px;font-weight:600}
.op{flex:none;display:inline-flex;align-items:center;gap:8px;height:44px;padding:0 14px 0 6px;border-radius:999px;background:var(--card);border:1.5px solid var(--line);font-weight:500;color:#3d4d48;white-space:nowrap}
[dir=rtl] .op{padding:0 6px 0 14px}
.op i{flex:none;font-style:normal;width:32px;height:32px;border-radius:50%;display:grid;place-items:center;background:#e9efec;color:#2c3d38;font-weight:700;font-size:15px}
.op.cur{background:var(--a3);border-color:var(--a3);color:#fff}.op.cur i{background:#fff;color:var(--a3)}
.ops.pick{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));overflow:visible;padding:0}.ops.pick .op{height:56px;font-size:16px;border-radius:16px}
dialog.opd .btn{width:100%}
.cats.wrap{flex-wrap:wrap;overflow:visible;padding:0}
.fld .lbl{font-size:13.5px;color:var(--mut);font-weight:500}
.amtb{border:1.5px solid var(--line);background:var(--card);border-radius:14px;min-height:64px;padding:0 16px;display:flex;align-items:center;justify-content:space-between;gap:10px;font:inherit;color:var(--ink);text-align:start}
.amtb b{font-size:24px;font-weight:600}.amtb b .n{color:var(--a3)}.amtb:active{transform:scale(.99)}
.card>.srows,.card.col>.srows{margin:0 -8px}
.bars{height:150px}
/* login and the lock screen */
.login{flex-direction:column;display:flex;align-items:center;justify-content:center}
.login form{padding:26px 22px;gap:14px}
.login .fld input{min-height:54px;font-size:17px}
.pw{position:relative}.pw input{width:100%;padding-inline-end:76px}
.pw button{position:absolute;inset-block:6px;inset-inline-end:6px;border:0;border-radius:10px;background:#eef3f0;color:var(--a3);font:600 14px var(--f);padding:0 14px}
#lock{position:fixed;inset:0;z-index:9999;background:var(--bg);display:grid;place-items:center;padding:20px;overflow-y:auto}
.lk{width:100%;max-width:340px;display:flex;flex-direction:column;align-items:center;gap:10px;text-align:center}
.lk h2{margin:0}.lk p{margin:0}
.lk-i{width:60px;height:60px;border-radius:19px;background:var(--a3);color:#fff;display:grid;place-items:center}
.lk-dots{display:flex;gap:16px;direction:ltr;margin:14px 0 2px}
.lk-dots i{width:18px;height:18px;border-radius:50%;box-shadow:inset 0 0 0 2px #b9c8c2;transition:background .12s,transform .12s}
.lk-dots i.on{background:var(--a3);box-shadow:none;transform:scale(1.1)}
.lk-dots.bad{animation:lkshake .32s}.lk-dots.bad i{box-shadow:inset 0 0 0 2px var(--bad)}
@keyframes lkshake{20%{transform:translateX(-9px)}40%{transform:translateX(9px)}60%{transform:translateX(-6px)}80%{transform:translateX(6px)}}
.lk-msg{min-height:22px;color:var(--bad);font-weight:600}
.lk-keys{width:100%;margin-bottom:8px}.lk-keys.off{opacity:.35;pointer-events:none}
.hb{width:40px;height:40px;border-radius:12px;border:1.5px solid var(--line);background:var(--card);color:var(--mut);display:grid;place-items:center;flex:none}
.hb[hidden]{display:none}
.side .hb{border:0}.side .hb:hover{background:#e3ebe7;color:var(--a3)}
