/* ===========================================================
   pro.css — styles for the Cashier tab and the 3D front page.
   Loaded after styles.css; only adds new classes (cx-*, gs-3d-*).
   =========================================================== */

/* ---------- 3D hero ---------- */
.gs-fp-hero.gs-3d-on{min-height:520px;overflow:hidden;display:flex;align-items:center;}
.gs-fp-hero.gs-3d-on .gs-fp-hero-inner{position:relative;z-index:2;}
.gs-3d-wrap{position:absolute;inset:0;z-index:1;pointer-events:none;}
.gs-3d-wrap canvas{display:block;width:100%;height:100%;}
@media (min-width:900px){
  .gs-fp-hero.gs-3d-on{padding-top:72px;padding-bottom:72px;}
  .gs-fp-hero.gs-3d-on .gs-fp-hero-inner{margin-left:6%;margin-right:auto;text-align:left;max-width:520px;}
}
@media (max-width:599px){
  .gs-fp-hero.gs-3d-on{min-height:600px;align-items:flex-end;}
  .gs-fp-hero.gs-3d-on .gs-fp-hero-inner{padding-top:230px;}
}
@media (prefers-reduced-motion:reduce){ .gs-3d-wrap{opacity:.9;} }

/* ---------- Cashier tab ---------- */
.cx{display:flex;flex-direction:column;gap:14px;}
.cx-bar{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;}
.cx-term-name{font-size:13px;color:var(--ink-soft);}
.cx-term-name button{background:none;border:1px dashed var(--border);border-radius:8px;padding:4px 10px;font:inherit;font-weight:600;color:var(--teal);cursor:pointer;}
.cx-bar-r{display:flex;align-items:center;gap:10px;}
.cx-conn{font-size:12px;font-weight:700;color:#8A6D1D;}
.cx-conn.on{color:var(--green);}
.cx-cols{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(320px,1fr);gap:16px;align-items:start;}
.cx-main{min-width:0;}
.cx-side{display:flex;flex-direction:column;gap:14px;min-width:0;}
.cx-search{display:flex;gap:8px;margin-bottom:12px;position:sticky;top:0;z-index:3;background:var(--cream);padding:2px 0 6px;}
.cx-search input{flex:1;min-width:0;padding:13px 14px;font-size:15px;border:1.5px solid var(--border);border-radius:var(--radius);background:#fff;}
.cx-search input:focus{outline:none;border-color:var(--teal);box-shadow:0 0 0 3px rgba(31,59,54,.12);}
.cx-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(138px,1fr));gap:10px;}
.cx-tile{display:flex;flex-direction:column;align-items:flex-start;gap:4px;text-align:left;padding:10px;border:1px solid var(--border);border-radius:var(--radius);background:#fff;cursor:pointer;font:inherit;color:var(--ink);transition:transform .08s,box-shadow .15s,border-color .15s;min-height:132px;}
.cx-tile:hover{border-color:var(--teal);box-shadow:0 4px 14px rgba(31,59,54,.12);}
.cx-tile:active{transform:scale(.97);}
.cx-tile b{font-size:13px;line-height:1.25;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;}
.cx-tile img,.cx-tile-ph{width:100%;height:56px;object-fit:cover;border-radius:7px;background:#F1E8D3;}
.cx-tile-ph{display:flex;align-items:center;justify-content:center;font-family:'Fraunces',serif;font-size:24px;color:var(--teal);}
.cx-price{font-weight:700;color:var(--teal);font-size:13px;}
.cx-stock{font-size:10.5px;color:var(--ink-soft);}
.cx-stock.low{color:var(--rose);font-weight:700;}
.cx-tile.out{opacity:.5;cursor:not-allowed;}
.cx-card{background:#fff;border:1px solid var(--border);border-radius:12px;padding:14px;}
.cx-card-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:10px;}
.cx-card-head h3{margin:0;font-size:14px;font-family:'Fraunces',serif;color:var(--teal);}
.cx-lines{max-height:300px;overflow:auto;margin:0 -4px;padding:0 4px;}
.cx-line{display:grid;grid-template-columns:1fr auto auto 24px;gap:8px;align-items:center;padding:8px 0;border-bottom:1px solid #F0EAD7;}
.cx-line-name{display:flex;flex-direction:column;min-width:0;}
.cx-line-name b{font-size:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.cx-line-name span{font-size:11px;color:var(--ink-soft);}
.cx-qty{display:flex;align-items:center;gap:6px;}
.cx-qty button{width:30px;height:30px;border-radius:8px;border:1px solid var(--border);background:var(--cream);font-size:17px;cursor:pointer;line-height:1;}
.cx-qty button:active{background:#EFE6CC;}
.cx-qty span{min-width:20px;text-align:center;font-weight:700;}
.cx-line-total{font-weight:700;font-size:13px;min-width:72px;text-align:right;}
.cx-x{background:none;border:none;color:var(--ink-soft);font-size:20px;line-height:1;cursor:pointer;padding:0;}
.cx-x:hover{color:var(--rose);}
.cx-empty{padding:16px 6px;text-align:center;color:var(--ink-soft);font-size:12.5px;}
.cx-opts{display:grid;grid-template-columns:1fr auto;gap:8px;margin:12px 0 4px;}
.cx-opts select,.cx-opts input{padding:9px 10px;border:1px solid var(--border);border-radius:8px;font:inherit;font-size:13px;background:#fff;min-width:0;}
.cx-disc{display:flex;gap:4px;}.cx-disc input{width:88px;}
.cx-totals{margin-top:8px;}
.cx-row{display:flex;justify-content:space-between;align-items:center;padding:4px 0;font-size:13px;}
.cx-row i{font-style:normal;font-size:11px;color:var(--ink-soft);margin-left:4px;}
.cx-total{border-top:2px solid var(--teal);margin-top:6px;padding-top:9px;font-size:18px;color:var(--teal);}
.cx-actions{display:grid;grid-template-columns:1fr 1fr 2fr;gap:8px;margin-top:12px;}
.cx-pay{font-size:16px;padding:14px;}
.cx-done{display:flex;justify-content:space-between;align-items:center;gap:8px;background:var(--green-bg);color:var(--green);border-radius:9px;padding:9px 11px;margin-bottom:10px;font-size:12.5px;animation:cxpop .35s ease-out;}
@keyframes cxpop{from{transform:scale(.96);opacity:0}to{transform:none;opacity:1}}
.cx-terms{display:flex;flex-direction:column;gap:8px;}
.cx-term{display:grid;grid-template-columns:14px 1fr auto;gap:10px;align-items:center;padding:8px 10px;border-radius:9px;background:var(--cream);}
.cx-term b{display:block;font-size:13px;}.cx-term b i{font-style:normal;font-weight:500;color:var(--ink-soft);font-size:11px;}
.cx-term span{font-size:11px;color:var(--ink-soft);}
.cx-term-r{text-align:right;}.cx-term-r b{color:var(--teal);}
.cx-dot{width:10px;height:10px;border-radius:50%;background:#B9C2B6;}
.cx-term.busy .cx-dot{background:var(--green);box-shadow:0 0 0 4px rgba(76,122,92,.2);animation:cxpulse 1.6s infinite;}
@keyframes cxpulse{50%{box-shadow:0 0 0 7px rgba(76,122,92,0);}}
.cx-daytotal{font-size:16px;color:var(--teal);}
.cx-feed,.cx-held{display:flex;flex-direction:column;}
.cx-feedrow,.cx-heldrow{display:flex;justify-content:space-between;align-items:center;gap:8px;padding:8px 6px;border-bottom:1px solid #F0EAD7;border-radius:6px;}
.cx-feedrow b,.cx-heldrow b{font-size:13px;display:block;}
.cx-feedrow span,.cx-heldrow span{font-size:11px;color:var(--ink-soft);display:block;}
.cx-feed-r{text-align:right;}
.cx-feedrow.fresh{animation:cxfresh 2.6s ease-out;}
@keyframes cxfresh{0%{background:#F6E7B0;}100%{background:transparent;}}
.cx-toast{position:fixed;left:50%;bottom:28px;transform:translate(-50%,30px);background:var(--teal);color:#fff;padding:12px 18px;border-radius:12px;font-size:13.5px;font-weight:600;box-shadow:0 10px 30px rgba(0,0,0,.25);opacity:0;transition:.28s;z-index:99999;max-width:90vw;}
.cx-toast.show{opacity:1;transform:translate(-50%,0);}
.cx-paymodal{max-width:420px;}
.cx-bigtotal{font-family:'Fraunces',serif;font-size:38px;text-align:center;color:var(--teal);margin:4px 0 12px;}
.cx-methods{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin-bottom:12px;}
.cx-methods label{cursor:pointer;}.cx-methods input{display:none;}
.cx-methods span{display:block;text-align:center;padding:11px 6px;border:1.5px solid var(--border);border-radius:9px;font-size:13px;font-weight:600;}
.cx-methods input:checked + span{border-color:var(--teal);background:var(--teal);color:#fff;}
.cx-quick{display:flex;gap:6px;flex-wrap:wrap;margin:6px 0 10px;}
.cx-change{font-size:14px;color:var(--ink-soft);}.cx-change b{color:var(--green);font-size:18px;}
.cx-err{color:var(--rose);font-size:12.5px;min-height:16px;margin-top:6px;}
@media (max-width:900px){
  .cx-cols{grid-template-columns:1fr;}
  .cx-side{order:-1;}
  .cx-lines{max-height:220px;}
  .cx-grid{grid-template-columns:repeat(auto-fill,minmax(120px,1fr));}
}

/* ---------- Cash desk, previous bills, daily report, bulk delete ---------- */
.gs-modal.cx-wide{max-width:980px;width:96vw;max-height:92vh;overflow:auto;}
.gs-modal.cx-tall{height:92vh;display:flex;flex-direction:column;} .gs-modal.cx-tall #dy-root{flex:1;display:flex;flex-direction:column;min-height:0;}
.cx-filters{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin:8px 0;}
.cx-filters input,.cx-filters select{padding:9px 10px;border:1px solid var(--border);border-radius:8px;font:inherit;font-size:13px;background:#fff;}
.cx-filters input[type=text],.cx-filters input:not([type]){flex:1;min-width:180px;}
.cx-chk{display:inline-flex;align-items:center;gap:6px;font-size:12.5px;color:var(--ink-soft);cursor:pointer;}
.cx-bills-sum{font-size:12.5px;color:var(--ink-soft);margin:2px 0 8px;}
.cx-bills-wrap{max-height:50vh;overflow:auto;border:1px solid var(--border);border-radius:10px;}
.cx-bills-wrap table{margin:0;} .cx-bills-wrap th.r,.cx-bills-wrap td.r{text-align:right;}
.cx-bills-wrap thead th{position:sticky;top:0;background:#F4EFE0;z-index:1;}
tr.cx-refunded td{opacity:.55;text-decoration:line-through;} tr.cx-refunded td:last-child,tr.cx-refunded td .gs-badge{text-decoration:none;opacity:1;}
.muted{color:var(--ink-soft);font-size:11.5px;}
.cx-chip{font-weight:800;}
.cx-sub{margin:16px 0 6px;font-family:'Fraunces',serif;color:var(--teal);font-size:14px;}
.cx-dr-head{display:flex;justify-content:space-between;align-items:flex-start;gap:14px;flex-wrap:wrap;}
.cx-dr-big{background:var(--teal);color:#fff;border-radius:14px;padding:12px 20px;text-align:right;min-width:240px;}
.cx-dr-big span{display:block;font-size:11px;letter-spacing:1.2px;text-transform:uppercase;opacity:.8;} .cx-dr-big b{font-family:'Fraunces',serif;font-size:30px;display:block;} .cx-dr-big small{opacity:.9;}
.cx-dr-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:8px;margin:12px 0;}
.cx-dr-line{background:var(--cream);border:1px solid var(--border);border-radius:10px;padding:9px 12px;display:flex;flex-direction:column;gap:2px;font-size:12px;color:var(--ink-soft);}
.cx-dr-line b{font-size:16px;color:var(--ink);} .cx-dr-line i{font-style:normal;color:var(--rose);}
.cx-dr-line.in b{color:var(--green);} .cx-dr-line.out b{color:var(--rose);} .cx-dr-line.tot{background:var(--green-bg);border-color:#bcd7c4;} .cx-dr-line.tot b{color:var(--teal);}
.cx-dr-tills{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:8px;} .cx-dr-tills div{background:#fff;border:1px solid var(--border);border-radius:8px;padding:6px 10px;font-size:12px;display:flex;gap:10px;}
.cx-dr-actions{display:flex;gap:8px;flex-wrap:wrap;margin:8px 0;} .gs-btn.cx-in{border-color:var(--green);color:var(--green);}
.cx-var{margin:6px 0;font-size:14px;min-height:20px;}
.cx-frame{flex:1;width:100%;min-height:62vh;border:1px solid var(--border);border-radius:10px;background:#eceae3;margin-top:6px;}
.gs-modal textarea{width:100%;padding:9px 10px;border:1px solid var(--border);border-radius:8px;font:inherit;resize:vertical;box-sizing:border-box;}
.gs-bulkbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:6px 0 8px;}
.gs-bulk-ctl{display:flex;align-items:center;gap:8px;flex-wrap:wrap;} .gs-bulk-hint{font-size:12px;color:var(--ink-soft);}
.gs-bulk-cell{width:34px;text-align:center;} .gs-bulk-cell input{width:17px;height:17px;cursor:pointer;accent-color:var(--teal);}
table.gs-bulk-on tbody tr:has(.gs-bulk-cb:checked){background:#FBEFD0;}
