/* Visual reference: live CHAINARIS, 5 Nov 2026. No original application JavaScript. */

:root{--navy:#153653;--line:#d8e7ee;--bg:#f5fbfd;--text:#17344a;--muted:#6d8493;--blue:#e5f5ff;--mint:#e7faf3;--pink:#fff0f5;--yellow:#fff8df}*{box-sizing:border-box}body{margin:0;font-family:Tahoma,Arial,sans-serif;background:var(--bg);color:var(--text)}button,input,select{font:inherit}/* R11 top alignment, in FIRST stylesheet: offset 18px linebox ahead of app. */
body>.app{margin-top:-18px!important}
/* SQR Request nested top banner must align with logo as well. */
#sqrform #sqrFormHost>main.main{padding-top:0!important}
.app{display:flex;min-height:100vh}.side{width:285px;position:fixed;inset:0 auto 0 0;background:#030164;padding:16px;color:#fff;overflow:auto}.logo{width:100%;max-height:70px;object-fit:contain;background:#fff;border-radius:14px;padding:8px;margin-bottom:10px}.role{display:flex;background:#ffffff16;padding:4px;border-radius:12px;margin:8px 0 14px}.role button{flex:1;border:0;padding:8px;border-radius:9px;background:transparent;color:#dbeef8}.role .active{background:#e5f8f3;color:#174d48;font-weight:700}.menutitle{font-size:11px;opacity:.6;margin:8px}.menu button{width:100%;border:0;background:transparent;color:#eef8fc;text-align:left;padding:11px;border-radius:10px;margin:2px 0;cursor:pointer}.menu button.active,.menu button:hover{background:#ffffff18}.badge{float:right;background:#ffd8e6;color:#8a3f60;padding:2px 7px;border-radius:999px;font-size:11px;font-weight:700}.main{margin-left:285px;width:calc(100% - 285px);padding:22px 26px 50px}.page{display:none}.page.active{display:block}.title{font-size:23px;font-weight:800;background:linear-gradient(135deg,#dff1ff,#e9fbf5,#fff1f7);border:1px solid #cfe5ee;border-radius:18px;padding:17px 20px;margin-bottom:14px}.toolbar{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin-bottom:14px;justify-content:flex-end}.toolbar input,.toolbar select{border:1px solid var(--line);background:#fff;border-radius:11px;padding:10px 12px}.search{min-width:340px}.btn{border:0;border-radius:10px;padding:9px 12px;background:#2f9e89;color:#fff;cursor:pointer}.btn.sec{background:#e6f5fb;color:#22617d}.btn.pink{background:#f8dbe7;color:#7d3e5a}.btn.navy{background:var(--navy)}.cards{display:grid;grid-template-columns:repeat(4,1fr);gap:13px;margin-bottom:16px}.card,.panel{background:#fff;border:1px solid var(--line);border-radius:17px;box-shadow:0 6px 18px #1a5b7410}.card{padding:16px}.card:nth-child(1){background:linear-gradient(135deg,#eef9ff,#fff)}.card:nth-child(2){background:linear-gradient(135deg,#fff8df,#fff)}.card:nth-child(3){background:linear-gradient(135deg,#fff0f5,#fff)}.card:nth-child(4){background:linear-gradient(135deg,#eafbf5,#fff)}.n{font-size:28px;font-weight:800;margin-top:6px}.muted{color:var(--muted);font-size:12px}.panel{padding:15px;margin-bottom:15px}.panel h3{margin:-15px -15px 12px;padding:12px 15px;background:linear-gradient(90deg,#dff4ff,#e7fbf5);border-radius:17px 17px 0 0;font-size:15px}.table{width:100%;border-collapse:collapse;font-size:13px}.table th{background:#eaf8fb;text-align:left;padding:10px}.table td{padding:10px;border-bottom:1px solid #edf3f5;vertical-align:middle}.status{padding:5px 8px;border-radius:999px;background:#e4f7ef;color:#237b65;font-size:11px}.status.new{background:#fff0d7;color:#93631c}.newdot{color:#d74e75;font-weight:800}.actions{display:flex;gap:6px;flex-wrap:wrap}.note{background:#fff9e8;border:1px solid #f0dfac;border-radius:12px;padding:11px;font-size:12px}.modal{display:none;position:fixed;inset:0;background:#102f4988;z-index:50;align-items:center;justify-content:center;padding:25px}.modal.show{display:flex}.box{background:#fff;border-radius:20px;width:min(980px,96vw);max-height:90vh;overflow:auto;padding:20px}.head{display:flex;justify-content:space-between;align-items:center;margin-bottom:12px}.head b{font-size:18px}.x{border:0;background:#eaf8fb;border-radius:10px;padding:8px 11px}.twocol{display:grid;grid-template-columns:1fr 1fr;gap:12px}.graphgrid{display:grid;grid-template-columns:repeat(3,1fr);gap:13px}.graph{height:130px;display:flex;align-items:end;gap:10px;padding:15px;border-left:1px solid var(--line);border-bottom:1px solid var(--line)}.bar{flex:1;background:#c7e8f6;border-radius:6px 6px 0 0}.req{color:#d95873;font-weight:700}.hide{display:none!important}@media(max-width:950px){.side{width:220px}.main{margin-left:220px;width:calc(100% - 220px)}.cards,.graphgrid,.twocol{grid-template-columns:1fr}.search{min-width:180px}}
@media(max-width:1100px){.latest-grid{grid-template-columns:1fr!important}}

/* V24 integration isolation */
#sqrFormHost .sqr-request-tab{display:inline-flex;align-items:center;min-height:40px;padding:9px 14px;border-radius:7px;background:#eaf4ff;color:#174a87;font-weight:800;border:1px solid #dce6f2}

#sqrFormHost,#quotationFormHost{width:100%;min-height:100%;background:#fff;overflow:visible}
#sqrFormHost .side,#quotationFormHost .side{display:none!important}
#sqrFormHost .main,#quotationFormHost .main{margin-left:0!important;width:100%!important;max-width:none!important}

#sqrFormHost *{box-sizing:border-box} #sqrFormHost :root{--navy:#073a86;--blue:#1877f2;--line:#dce6f2;--soft:#edf6ff;--bg:#f5f8fc;--text:#183153;--muted:#71849c;--green:#159447;--red:#d93025}
#sqrFormHost{margin:0;font-family:Arial,Tahoma,sans-serif;background:var(--bg);color:var(--text)}
#sqrFormHost button, #sqrFormHost input, #sqrFormHost select, #sqrFormHost textarea{font:inherit}#sqrFormHost .side{position:fixed;left:0;top:0;bottom:0;width:255px;background:var(--navy);border-left:9px solid #087cff;color:#fff;padding:22px 14px;overflow:auto}
#sqrFormHost .brand{font-size:22px;font-weight:800;margin:0 10px 20px}#sqrFormHost .brand small{display:block;font-size:11px;font-weight:400;opacity:.8;margin-top:4px}
#sqrFormHost .nav button{width:100%;border:0;background:transparent;color:#fff;text-align:left;padding:11px 12px;border-radius:8px;margin:2px 0;cursor:pointer}#sqrFormHost .nav button:hover, #sqrFormHost .nav button.on{background:var(--blue)}
#sqrFormHost .main{margin-left:255px}#sqrFormHost .top{height:68px;background:#fff;border-bottom:1px solid var(--line);padding:13px 26px;display:flex;align-items:center;justify-content:space-between;gap:18px;position:sticky;top:0;z-index:5}
#sqrFormHost .search{max-width:620px;width:58%}#sqrFormHost .content{padding:24px}#sqrFormHost .page{display:none}#sqrFormHost .page.on{display:block}
#sqrFormHost .panel, #sqrFormHost .card{background:#fff;border:1px solid var(--line);border-radius:12px;padding:18px}#sqrFormHost .panel{margin-top:14px}#sqrFormHost .hero{background:linear-gradient(120deg,#eaf4ff,#fff);border:1px solid var(--line);border-radius:14px;padding:22px}
#sqrFormHost .cards{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin:14px 0}#sqrFormHost .num{font-size:30px;font-weight:800;margin-top:8px}
#sqrFormHost .section{background:#eaf4ff;border-left:4px solid var(--blue);padding:9px 12px;border-radius:6px;font-weight:800;margin:16px 0 10px}
#sqrFormHost .grid2{display:grid;grid-template-columns:1fr 1fr;gap:18px}#sqrFormHost .grid3{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}#sqrFormHost .field{margin:9px 0}#sqrFormHost .field label{display:block;font-size:13px;font-weight:700;margin-bottom:5px}
#sqrFormHost #sqrIdentityFields{grid-template-areas:"customer date" "contact sales" "project .";gap:0 18px}
#sqrFormHost #sqrIdentityFields>div{display:contents}
#sqrFormHost #sqrIdentityFields>div:first-child>.field:first-child{display:none}
#sqrFormHost #sqrIdentityFields>div:first-child>.field:nth-child(2){grid-area:customer}
#sqrFormHost #sqrIdentityFields>div:first-child>.field:nth-child(3){grid-area:project}
#sqrFormHost #sqrIdentityFields>div:last-child>.field:nth-child(1){grid-area:date}
#sqrFormHost #sqrIdentityFields>div:last-child>.field:nth-child(2){grid-area:contact}
#sqrFormHost #sqrIdentityFields>div:last-child>.field:nth-child(3){grid-area:sales}
@media(max-width:950px){#sqrFormHost #sqrIdentityFields{grid-template-columns:1fr;grid-template-areas:"customer" "contact" "project" "date" "sales"}}
#sqr.active #sqrMainTable:not(:has(tr[data-cnr-live-request-id],tr.cnr-live-sqr-empty)){visibility:hidden!important}
#sqrFormHost input, #sqrFormHost select, #sqrFormHost textarea{width:100%;border:1px solid #cbd8e8;border-radius:7px;padding:9px 10px;background:#fff}#sqrFormHost textarea{min-height:74px;resize:vertical}#sqrFormHost input:disabled{background:#f1f4f8;color:#6f7f91}
#sqrFormHost .btn{border:0;border-radius:7px;padding:9px 13px;font-weight:700;cursor:pointer}#sqrFormHost .primary{background:var(--blue);color:#fff}#sqrFormHost .secondary{background:#eaf2fb;color:#174a87}#sqrFormHost .green{background:var(--green);color:#fff}#sqrFormHost .danger{background:#feeceb;color:var(--red)}
#sqrFormHost .actions{display:flex;gap:8px;justify-content:flex-end;align-items:center;margin-top:12px}#sqrFormHost .muted{color:var(--muted)}#sqrFormHost .hidden{display:none!important}
#sqrFormHost table{width:100%;border-collapse:collapse;background:#fff}#sqrFormHost th, #sqrFormHost td{border-bottom:1px solid #e8eef5;padding:8px;vertical-align:middle;text-align:left}#sqrFormHost th{background:#f3f7fb;font-size:12px;white-space:nowrap}#sqrFormHost td input, #sqrFormHost td select{min-width:80px;padding:7px}
#sqrFormHost .tablewrap{overflow:auto;border:1px solid var(--line);border-radius:8px}#sqrFormHost .quick{border:1px dashed #78a9e2;background:#f8fbff;border-radius:9px;padding:13px}#sqrFormHost .quick textarea{min-height:115px}
#sqrFormHost .summary{display:flex;justify-content:flex-end;margin-top:10px}#sqrFormHost .summarybox{width:330px}#sqrFormHost .sumrow{display:flex;justify-content:space-between;padding:6px 0}#sqrFormHost .grand{font-size:18px;font-weight:800;border-top:1px solid var(--line);margin-top:5px;padding-top:10px}
#sqrFormHost .checks{display:flex;gap:18px;flex-wrap:wrap}#sqrFormHost .checks label{font-weight:400}#sqrFormHost .checks input{width:auto;margin-right:5px}#sqrFormHost .notice{padding:10px 12px;border-radius:8px;background:#fff8e7;border:1px solid #f0d78a}
#sqrFormHost .modal{position:fixed;inset:0;background:rgba(9,30,66,.45);z-index:20;display:flex;align-items:flex-start;justify-content:center;padding:24px;overflow:auto}#sqrFormHost .modalbox{width:min(1180px,100%);background:#fff;border-radius:12px;box-shadow:0 18px 55px rgba(0,0,0,.25);overflow:hidden}
#sqrFormHost .modalhead{background:var(--blue);color:#fff;padding:15px 20px;display:flex;justify-content:space-between;align-items:center;font-size:19px;font-weight:800}#sqrFormHost .x{border:0;background:transparent;color:#fff;font-size:24px;cursor:pointer}#sqrFormHost .modalbody{padding:18px}
#sqrFormHost .contact input{min-width:120px}#sqrFormHost .trash{border:0;background:transparent;color:var(--red);cursor:pointer;font-size:18px}
#sqrFormHost .role{font-size:12px;color:var(--muted)}#sqrFormHost .tag{display:inline-block;padding:4px 8px;border-radius:12px;background:#eaf4ff;font-size:12px}
@media(max-width:900px){#sqrFormHost .side{position:static;width:auto}#sqrFormHost .main{margin-left:0}#sqrFormHost .top{position:static}#sqrFormHost .grid2, #sqrFormHost .grid3, #sqrFormHost .cards{grid-template-columns:1fr}#sqrFormHost .content{padding:14px}#sqrFormHost .search{width:100%}}

#sqrFormHost .termrow, #sqrFormHost .optionrow{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:9px 0}
#sqrFormHost .termrow label, #sqrFormHost .optionrow label, #sqrFormHost .optionlist>label{display:flex;align-items:center;min-height:36px}
#sqrFormHost .termrow input[type=checkbox], #sqrFormHost .optionrow input[type=checkbox], #sqrFormHost .optionlist>label input{width:auto;margin-right:6px}
#sqrFormHost .inlinefield{display:inline-flex;align-items:center;gap:6px}#sqrFormHost .smallnum{width:82px!important}
#sqrFormHost .percentwrap{position:relative;display:inline-block;width:82px}#sqrFormHost .percentwrap input{width:82px!important;padding-right:23px}#sqrFormHost .percentwrap:after{content:"%";position:absolute;right:9px;top:50%;transform:translateY(-50%);color:#60748a}
#sqrFormHost .detailbox{width:330px;max-width:100%}#sqrFormHost .optionlist{display:grid;gap:8px}#sqrFormHost .lineTotal[readonly]{background:#f1f4f8;text-align:right}

#sqrFormHost .sqr-banner{width:100%;display:block;border-radius:14px;margin:0 0 18px;box-shadow:0 4px 14px rgba(24,119,242,.10)}
#sqrFormHost .section{display:flex;align-items:center;gap:8px}#sqrFormHost .section .secemoji{font-size:22px;line-height:1}
#sqrFormHost .send-options{display:grid;gap:15px;margin-top:4px}#sqrFormHost .send-options .optionrow{padding:3px 0}#sqrFormHost .send-options .detailbox{margin-left:8px}
#sqrFormHost .lineTotal[readonly]{min-width:105px;border:1px solid #cbd8e8;border-radius:7px;padding:7px 9px;background:#f1f4f8;text-align:right;color:#183153}

#sqrFormHost /* Approved SQR 3D section icons */
.section .secicon{
  width:42px;height:42px;object-fit:contain;border-radius:10px;background:#fff;
  flex:0 0 38px;margin-right:2px;
}
#sqrFormHost .section{min-height:50px}

#sqrFormHost /* Deposit installments */
.deposit-plan{
  margin:6px 0 12px 28px;padding:12px 14px;
  border:1px solid #d7e6f6;border-radius:9px;background:#f8fbff;
  max-width:820px;
}
#sqrFormHost .deposit-head{display:flex;justify-content:space-between;gap:16px;align-items:center;margin-bottom:8px}
#sqrFormHost .deposit-row{
  display:grid;grid-template-columns:78px 110px 1fr 38px;
  gap:8px;align-items:center;margin:7px 0;
}
#sqrFormHost .deposit-row input{margin:0}
#sqrFormHost .deposit-percent{position:relative}
#sqrFormHost .deposit-percent input{padding-right:24px}
#sqrFormHost .deposit-percent:after{content:"%";position:absolute;right:9px;top:50%;transform:translateY(-50%);color:#60748a}
#sqrFormHost .add-installment{margin-top:7px}

#sqrFormHost /* Channel spacing: compact, #sqrFormHost aligned, #sqrFormHost no excessive gaps */
.send-options{display:grid;gap:6px!important;margin-top:2px!important}
#sqrFormHost .send-options .optionrow{
  display:flex;align-items:center;gap:8px!important;
  margin:0!important;padding:2px 0!important;min-height:40px;
}
#sqrFormHost .send-options .optionrow label{min-width:118px;min-height:34px;margin:0}
#sqrFormHost .send-options .detailbox{margin-left:0!important;width:360px}
#sqrFormHost .send-options input[type=file]{width:auto;max-width:430px}

@media(max-width:700px){
  #sqrFormHost .deposit-plan{margin-left:0}
  #sqrFormHost .deposit-row{grid-template-columns:72px 95px 1fr 34px}
  #sqrFormHost .send-options .optionrow{align-items:flex-start}
  #sqrFormHost .send-options .optionrow label{min-width:0}
}

#sqrFormHost .quick-choice{min-width:300px}#sqrFormHost .status-ok{color:#159447;font-weight:700}#sqrFormHost .status-warn{color:#b26a00;font-weight:700}#sqrFormHost #confirmAllBtn:disabled{opacity:.5;cursor:not-allowed}

#sqrFormHost /* Latest approved SQR refinements */
.section .secicon{width:46px!important;height:46px!important;object-fit:contain!important;border-radius:10px!important;background:transparent!important;padding:0!important;flex:0 0 46px!important}
#sqrFormHost .file-upload-native{position:absolute;left:-9999px;width:1px;height:1px;opacity:0}
#sqrFormHost .file-upload-btn{display:inline-flex;align-items:center;gap:7px;padding:10px 16px;border:1px solid #9fc7ee;border-radius:9px;background:#fff;color:#145fae;font-weight:700;cursor:pointer}
#sqrFormHost .file-name-list{margin-left:10px;color:#52677d;font-size:14px}

#sqrFormHost /* final requested refinements */
#requests{padding-top:0!important;margin-top:0!important}
#sqrFormHost #requests .sqr-banner{display:block;width:97%!important;margin:-18px auto 10px!important;border-radius:12px!important}
#sqrFormHost #requests .panel{margin-top:0!important}
#sqrFormHost #requests .section{margin-top:11px!important;margin-bottom:8px!important}
#sqrFormHost #requests .secicon{width:48px!important;height:48px!important;object-fit:contain!important;background:transparent!important;border-radius:0!important;padding:0!important}
#sqrFormHost .delivery-main-row{gap:18px!important;align-items:center!important;flex-wrap:wrap}
#sqrFormHost .delivery-days-label{display:inline-flex;align-items:center;gap:8px;font-weight:400}
#sqrFormHost .delivery-days-label .smallnum{width:86px}
#sqrFormHost .delivery-other-items{margin:8px 0 12px 26px;padding:10px 12px;border:1px dashed #cbd9ea;border-radius:10px;background:#fbfdff}
#sqrFormHost .delivery-item-row{display:flex;gap:10px;align-items:center;margin:7px 0;flex-wrap:wrap}
#sqrFormHost .delivery-item-row .item-no{width:78px}
#sqrFormHost .delivery-item-row .wait-days{width:92px}
#sqrFormHost .delivery-add{margin-top:6px}


#sqrFormHost .costgrid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}#sqrFormHost .costcard{background:#fff;border:1px solid #dce9f7;border-radius:14px;padding:14px;box-shadow:0 3px 10px rgba(25,55,95,.06)}#sqrFormHost .costcard small{display:block;margin-bottom:7px;color:#42566d}#sqrFormHost .costcard:nth-child(3) small,#sqrFormHost .costcard:nth-child(4) small{white-space:nowrap;font-size:11px}#sqrFormHost .costcard b{font-size:17px;color:#173b69}#sqrFormHost .muted{font-size:12px;color:#6b7b8e}@media(max-width:900px){#sqrFormHost .costgrid{grid-template-columns:repeat(2,minmax(0,1fr))}}
#sqrFormHost .delivery-free-input{width:100%;margin-top:12px;min-height:38px}


#sqrFormHost #requests .sqr-banner{display:block!important;width:97%!important;height:5cm!important;object-fit:fill!important;object-position:center!important;margin:-18px auto 10px!important;border-radius:12px!important}


#quotationFormHost *{box-sizing:border-box} #quotationFormHost :root{--navy:#073a86;--blue:#1877f2;--soft:#eaf4ff;--line:#dce6f2;--bg:#f5f8fc;--text:#183153;--muted:#71849c;--green:#159447;--red:#d93025}
#quotationFormHost{margin:0;font-family:Arial,Tahoma,sans-serif;background:var(--bg);color:var(--text)} #quotationFormHost input, #quotationFormHost select, #quotationFormHost textarea, #quotationFormHost button{font:inherit}
#quotationFormHost .side{position:fixed;left:0;top:0;bottom:0;width:255px;background:var(--navy);border-left:9px solid #087cff;color:#fff;padding:22px 14px}
#quotationFormHost .brand{font-size:22px;font-weight:800;margin:0 10px 20px} #quotationFormHost .brand small{display:block;font-size:11px;font-weight:400;opacity:.8;margin-top:4px}
#quotationFormHost .nav div{padding:11px 12px;border-radius:8px;margin:2px 0} #quotationFormHost .nav .on{background:var(--blue)}
#quotationFormHost .main{margin-left:255px} #quotationFormHost .top{height:54px;background:#fff;border-bottom:1px solid var(--line);padding:10px 24px;display:flex;align-items:center;justify-content:space-between}
#quotationFormHost .content{padding:12px 20px 28px} #quotationFormHost .bannerwrap{background:var(--soft);padding:3px 0;border-radius:12px;margin-bottom:10px}
#quotationFormHost .banner{display:block;width:100%;height:auto;max-height:none;object-fit:contain;border-radius:12px}
#quotationFormHost .titleline{display:flex;justify-content:space-between;align-items:center;background:#fff;border:1px solid var(--line);border-radius:10px;padding:10px 14px;margin-bottom:10px}
#quotationFormHost .titleline b{font-size:19px} #quotationFormHost .tag{background:#edf6ff;padding:5px 9px;border-radius:12px;font-size:12px}
#quotationFormHost .section{background:var(--soft);border-left:4px solid var(--blue);padding:9px 12px;border-radius:6px;font-weight:800;margin:12px 0 8px}
#quotationFormHost .panel{background:#fff;border:1px solid var(--line);border-radius:10px;padding:13px}
#quotationFormHost .grid2{display:grid;grid-template-columns:1fr 1fr;gap:12px 18px} #quotationFormHost .grid3{display:grid;grid-template-columns:repeat(4,1fr);gap:12px}
#quotationFormHost .field label{display:block;font-size:13px;font-weight:700;margin-bottom:5px} #quotationFormHost input, #quotationFormHost select, #quotationFormHost textarea{width:100%;border:1px solid #cbd8e8;border-radius:7px;padding:8px 10px;background:#fff}
#quotationFormHost input[readonly]{background:#f4f7fa} #quotationFormHost textarea{min-height:68px;resize:vertical}
#quotationFormHost .quick{border:1px dashed #78a9e2;background:#f8fbff;border-radius:9px;padding:11px} #quotationFormHost .quick textarea{min-height:88px}
#quotationFormHost .btn{border:0;border-radius:7px;padding:8px 12px;font-weight:700;cursor:pointer} #quotationFormHost .primary{background:var(--blue);color:#fff} #quotationFormHost .secondary{background:#eaf2fb;color:#174a87} #quotationFormHost .green{background:var(--green);color:#fff}
#quotationFormHost .actions{display:flex;gap:8px;justify-content:flex-end;margin-top:10px}
#quotationFormHost .tablewrap{overflow:auto;border:1px solid var(--line);border-radius:8px} #quotationFormHost .desc{min-width:420px;min-height:84px;resize:vertical;line-height:1.45} #quotationFormHost .locked{background:#f4f7fa!important;color:#52657a} #quotationFormHost .source-note{font-size:11px;color:#71849c;margin-top:4px}#quotationFormHost .vertical-fields{display:grid!important;grid-template-columns:1fr!important;gap:10px}#quotationFormHost .remark-vertical{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:10px}#quotationFormHost .remark-vertical .checks{display:flex!important;flex-direction:column!important;align-items:flex-start!important;gap:10px} #quotationFormHost table{width:100%;border-collapse:collapse} #quotationFormHost th, #quotationFormHost td{padding:7px;border-bottom:1px solid #e8eef5;text-align:left;vertical-align:middle} #quotationFormHost th{background:#f3f7fb;font-size:12px} #quotationFormHost td input, #quotationFormHost td select{min-width:72px;padding:7px}
#quotationFormHost .summary{display:flex;justify-content:flex-end;margin-top:8px} #quotationFormHost .summarybox{width:350px} #quotationFormHost .sumrow{display:flex;justify-content:space-between;padding:5px 0} #quotationFormHost .grand{font-weight:800;font-size:18px;border-top:1px solid var(--line);padding-top:8px}
#quotationFormHost .checks{display:flex;align-items:center;gap:16px;flex-wrap:wrap} #quotationFormHost .checks label{display:flex;align-items:center;gap:6px} #quotationFormHost .checks input[type=checkbox], #quotationFormHost .checks input[type=radio]{width:auto}
#quotationFormHost .inline{display:inline-flex;align-items:center;gap:7px} #quotationFormHost .mini{width:92px!important} #quotationFormHost .muted{color:var(--muted);font-size:12px}
#quotationFormHost .signgrid{display:grid;grid-template-columns:1fr 1fr 1fr;gap:14px} #quotationFormHost .sign{border:1px solid var(--line);border-radius:8px;padding:10px;min-height:94px}
@media(max-width:900px){#quotationFormHost .side{display:none}#quotationFormHost .main{margin-left:0}#quotationFormHost .grid2, #quotationFormHost .grid3, #quotationFormHost .signgrid{grid-template-columns:1fr}}

#quotationFormHost .section{display:flex;align-items:center;gap:8px}#quotationFormHost .secicon{width:38px;height:38px;object-fit:contain;object-position:center;border-radius:0;flex:0 0 38px;background:transparent!important}#quotationFormHost .internal{background:#fff8e8;border:1px solid #f0d79b}#quotationFormHost .internal-title{color:#8a5a00}#quotationFormHost .costgrid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px}#quotationFormHost .costcard{background:#fff;border:1px solid #ead9ad;border-radius:9px;padding:12px}#quotationFormHost .costcard small{display:block;color:#7b8795;margin-bottom:5px}#quotationFormHost .costcard:nth-child(3) small,#quotationFormHost .costcard:nth-child(4) small{white-space:nowrap;font-size:11px}#quotationFormHost .costcard b{font-size:18px}#quotationFormHost .suffixfield{display:flex;align-items:center;gap:8px}#quotationFormHost .suffixfield input{max-width:120px}#quotationFormHost .filelist{display:grid;gap:8px;margin-bottom:10px}#quotationFormHost .fileitem{display:flex;align-items:center;gap:9px;padding:9px 10px;border:1px solid var(--line);border-radius:8px;background:#fbfdff}#quotationFormHost .fileitem input{width:auto}#quotationFormHost .fileitem .grow{flex:1}#quotationFormHost .badge{font-size:11px;padding:3px 7px;border-radius:10px;background:#eaf4ff;color:#27639d}#quotationFormHost .danger{color:#b42318}#quotationFormHost .banner{max-height:none}
@media(max-width:900px){#quotationFormHost .costgrid{grid-template-columns:1fr}}
#quotationFormHost .secicon{width:42px!important;height:42px!important;object-fit:contain!important;object-position:center!important;display:block!important;flex:0 0 42px!important;overflow:visible!important}
#quotationFormHost .internal-title .secicon{width:38px!important;height:38px!important;object-fit:contain!important;background:transparent!important;}#quotationFormHost \n

.bannerwrap{height:5cm!important;overflow:hidden!important;padding:0!important}
#quotationFormHost .banner{width:100%!important;height:5cm!important;object-fit:fill!important;object-position:center!important;border-radius:12px!important}
#menu{display:flex!important;flex-direction:column!important;gap:7px!important}.side{overflow-y:auto!important}#menu button{display:block!important;width:100%!important}


/* V56: Admin SQR send channel only. No changes to Dashboard or Warranty. */
#sqrFormHost .send-options .optionrow {
  display:flex!important;
  align-items:flex-start!important;
  justify-content:flex-start!important;
  flex-wrap:wrap!important;
  gap:8px!important;
}
#sqrFormHost .send-options .optionrow > label {
  display:inline-flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  flex:0 0 auto!important;
  width:auto!important;
  min-width:0!important;
  max-width:100%!important;
  gap:7px!important;
  text-align:left!important;
  white-space:normal!important;
}
#sqrFormHost .send-options .optionrow > label > input[type="checkbox"] {
  position:static!important;
  display:inline-block!important;
  width:17px!important;
  height:17px!important;
  flex:0 0 17px!important;
  margin:0!important;
  float:none!important;
  order:0!important;
}
#sqrFormHost .send-options .optionrow > .detailbox,
#sqrFormHost .send-options .optionrow > input[type="file"] {
  flex:0 1 auto!important;
  max-width:100%!important;
}


#sqrFormHost .panel.vertical-fields.checks:has(> label > input.mini) > label {
  position:relative!important; display:block!important; box-sizing:border-box!important;
  width:100%!important; max-width:100%!important; min-width:0!important;
  padding:0 0 0 27px!important; margin:5px 0!important;
  text-align:left!important; line-height:25px!important; justify-content:flex-start!important;
}
#sqrFormHost .panel.vertical-fields.checks:has(> label > input.mini) > label > input[type="checkbox"] {
  position:absolute!important; left:0!important; top:4px!important; right:auto!important;
  bottom:auto!important; transform:none!important; float:none!important;
  display:block!important; width:17px!important; min-width:17px!important;
  max-width:17px!important; height:17px!important; margin:0!important;
  opacity:1!important; visibility:visible!important; pointer-events:auto!important;
}


/* Exact panel: Quotation Warranty. Leave SQR, Dashboard, and logic untouched. */
#quotationFormHost .panel.vertical-fields.checks > label {
 display:flex!important; flex-direction:row!important; justify-content:flex-start!important;
 align-items:center!important; gap:7px!important; width:100%!important;
 box-sizing:border-box!important; margin:3px 0!important; padding:0!important;
 text-align:left!important; min-height:29px!important;
}
#quotationFormHost .panel.vertical-fields.checks > label > input[type="checkbox"] {
 position:static!important; inset:auto!important; float:none!important;
 order:-1!important; flex:0 0 16px!important; display:inline-block!important;
 width:16px!important; min-width:16px!important; max-width:16px!important;
 height:16px!important; margin:0!important; padding:0!important;
 opacity:1!important; visibility:visible!important; pointer-events:auto!important;
 appearance:auto!important; -webkit-appearance:checkbox!important;
}
#quotationFormHost .panel.vertical-fields.checks > label > input.mini {
 flex:0 0 72px!important; width:72px!important; min-width:0!important;
}


/* Admin SQR send controls: left anchored, no inherited grid/offsets. */
#sqrFormHost .send-options {display:flex!important;flex-direction:column!important;align-items:flex-start!important;justify-content:flex-start!important;width:100%!important;gap:10px!important;padding:0!important;margin:0!important}
#sqrFormHost .send-options .optionrow {display:flex!important;flex-direction:column!important;align-items:flex-start!important;justify-content:flex-start!important;width:100%!important;gap:6px!important;margin:0!important;padding:0!important}
#sqrFormHost .send-options .optionrow > label {display:flex!important;flex-direction:row!important;align-items:center!important;justify-content:flex-start!important;align-self:flex-start!important;flex:0 0 auto!important;width:max-content!important;max-width:100%!important;min-width:0!important;margin:0!important;padding:0!important;gap:9px!important;text-align:left!important;white-space:normal!important;position:static!important;transform:none!important}
#sqrFormHost .send-options .optionrow > label > input[type="checkbox"] {position:static!important;inset:auto!important;transform:none!important;float:none!important;order:0!important;display:inline-block!important;flex:0 0 17px!important;width:17px!important;min-width:17px!important;height:17px!important;margin:0!important;padding:0!important}
#sqrFormHost .send-options .optionrow > .detailbox,
#sqrFormHost .send-options .optionrow > input[type="file"] {align-self:flex-start!important;margin:0!important;max-width:100%!important}

/* SQR admin attachment: align the single upload button at the left edge. */
#sqrFormHost .file-upload-wrap{display:flex!important;justify-content:flex-start!important;align-items:center!important;text-align:left!important;margin-left:0!important;padding-left:0!important;width:100%!important}
#sqrFormHost .file-upload-wrap .file-upload-btn{position:static!important;transform:none!important;float:none!important;margin-left:0!important;margin-right:auto!important;align-self:flex-start!important}


#customerModal:not(.hidden){display:flex!important;align-items:center;justify-content:center;position:fixed;inset:0;z-index:11000;background:rgba(17,35,56,.55);padding:16px}
#customerModal>.modalbox{width:min(1150px,100%)!important;max-width:1150px;max-height:94vh;display:flex;flex-direction:column;border-radius:12px;overflow:hidden}
#customerModal .modalhead{flex-shrink:0;background:#176aa7;color:#fff;padding:17px 22px}
#customerModal .modalbody{overflow:auto;padding:20px 24px}
#customerModal .section{background:#eaf5ff;color:#145a93;padding:10px 14px;border-radius:6px;margin:14px 0}
#customerModal .grid2{display:grid;grid-template-columns:1fr 1fr;gap:22px}
#customerModal .contact{min-width:850px;width:100%}
#customerModal .actions{display:flex;justify-content:flex-end;gap:10px}
#cnr70-customer-view:not(.hidden){display:flex!important;position:fixed;inset:0;z-index:11001;background:rgba(17,35,56,.55);padding:16px;align-items:center;justify-content:center}
#cnr70-customer-view .cnr70-modalbox{width:min(1100px,100%);max-height:92vh;display:flex;flex-direction:column;overflow:hidden}
#cnr70-customer-view .modalbody{overflow:auto}
#cnr70-customer-view .cnr70-details{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
#cnr70-customer-view .cnr70-detail{padding:10px;border-bottom:1px solid #e1e9ef;display:flex;flex-direction:column;gap:5px}
#cnr70-customer-view .cnr70-detail b{color:#145a93}
@media(max-width:700px){#customerModal .grid2,#cnr70-customer-view .cnr70-details{grid-template-columns:1fr}}


/* Customer popup only: all existing field controls, ids and save handlers remain intact. */
#customerModal:not(.hidden){align-items:center!important;padding:20px!important;overflow-y:auto!important}
#customerModal .modalbox{width:min(1240px,calc(100vw - 32px))!important;max-height:calc(100dvh - 40px);display:flex;flex-direction:column;border-radius:14px!important;box-shadow:0 25px 85px rgba(9,31,61,.34)!important}
#customerModal .modalhead{flex:none;background:linear-gradient(105deg,#1466a8,#2188d2)!important;padding:18px 24px!important;font-size:20px!important;letter-spacing:.1px}
#customerModal .modalhead .x{width:36px;height:36px;border-radius:8px;background:#ffffff21;display:grid;place-items:center}
#customerModal .modalbody{overflow-y:auto;overscroll-behavior:contain;padding:18px 26px 24px!important;background:#fff}
#customerModal .section{margin:8px 0 16px!important;padding:11px 14px!important;background:#eaf5ff!important;border-left:5px solid #1877c9!important;color:#14578e!important;font-size:16px!important}
#customerModal .grid2{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr)!important;column-gap:28px!important;row-gap:4px!important}
#customerModal .field{margin:0 0 13px!important;min-width:0}
#customerModal .field>label{font-size:13px!important;font-weight:700!important;color:#344e66;margin-bottom:6px!important}
#customerModal .field input:not([type=radio]),#customerModal .field select,#customerModal .field textarea{min-height:40px;border:1px solid #cddbe8!important;border-radius:7px!important;padding:9px 11px!important;background:#fff!important;box-sizing:border-box}
#customerModal .field textarea{min-height:66px;resize:vertical}
#customerModal .field input:focus,#customerModal .field textarea:focus,#customerModal .field select:focus{outline:2px solid #91c8f8;outline-offset:0;border-color:#2787d1!important}
#customerModal .field input:disabled{background:#f0f4f8!important;color:#60748b}
#customerModal .checks{min-height:40px;align-items:center;flex-wrap:wrap;gap:18px!important}
#customerModal .checks label{display:inline-flex;align-items:center;gap:7px;white-space:nowrap;font-weight:500}
#customerModal .tablewrap{border:1px solid #dce7f0;border-radius:9px;overflow:auto!important}
#customerModal table.contact{min-width:800px;width:100%!important;border-collapse:collapse}
#customerModal table.contact thead th{background:#eaf5ff;color:#245778;font-weight:700;white-space:nowrap;padding:11px 8px!important}
#customerModal table.contact td{padding:7px 6px!important;vertical-align:middle}
#customerModal table.contact tbody tr:nth-child(even){background:#f8fbff}
#customerModal table.contact input{width:100%!important;min-width:90px;height:37px;box-sizing:border-box;padding:6px 8px!important}
#customerModal table.contact td:first-child{text-align:center;min-width:42px}
#customerModal table.contact td:last-child{text-align:center;min-width:48px}
#customerModal .actions{padding-top:14px;margin-top:14px!important;border-top:1px solid #e1e9f1;gap:10px!important}
#customerModal .actions .btn{min-width:118px;min-height:40px;font-weight:700}
#customerModal .btn.green{background:#198754!important;color:#fff}
@media(max-width:740px){#customerModal:not(.hidden){padding:8px!important}#customerModal .modalbox{width:100%!important;max-height:calc(100dvh - 16px)}#customerModal .modalbody{padding:14px!important}#customerModal .grid2{grid-template-columns:minmax(0,1fr)!important;gap:0!important}#customerModal .modalhead{padding:14px!important}}

#cnr70-customer-view.hidden{display:none!important}#cnr70-customer-view:not(.hidden){display:flex!important;position:fixed!important;inset:0!important;z-index:12000!important;background:rgba(14,34,59,.58)!important;align-items:center;justify-content:center;padding:18px}#cnr70-customer-view .modalbox{background:#fff;width:min(1120px,100%);max-height:92vh;overflow:hidden;border-radius:12px;box-shadow:0 18px 60px #0005}#cnr70-customer-view .modalbody{overflow:auto;max-height:calc(92vh - 65px)}#cnr70-customer-view .modalhead{background:#1877f2;color:#fff;display:flex;justify-content:space-between;align-items:center;padding:15px 20px}#cnr70-customer-view .cnr70-close{cursor:pointer}#customers #cnr46-customers .cnr46-filter-toggle{display:none!important}
/* V111: Right-align ONLY the product-search control in quotation item rows. Keep all locked layout/content/function unchanged. */
#quotationFormHost #rows tr > td:nth-child(2),
#quotationFormHost #rows tr > td:nth-child(2) .skuSearch,
#quotationFormHost #rows tr > td:nth-child(2) input[placeholder="ค้นหาสินค้า"] {
  text-align:left!important;
}
#quotationFormHost #rows tr > td:nth-child(2) {
  position:relative!important;
}
#quotationFormHost #rows tr > td:nth-child(2) .skuSearch,
#quotationFormHost #rows tr > td:nth-child(2) input[placeholder="ค้นหาสินค้า"] {
  display:block!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  margin-left:0!important;
  margin-right:0!important;
}


/* QA number is assigned on save for both roles; keep the input for snapshots/PDF. */
#quotationFormHost .qa-auto-number-field{display:none!important}
#quotationFormHost .panel.grid2 > .field:nth-child(2){grid-column:2;grid-row:1}
#quotationFormHost .panel.grid2 > .field:nth-child(3){grid-column:1;grid-row:1}
#quotationFormHost .panel.grid2 > .field:nth-child(4){grid-column:1;grid-row:2}
#quotationFormHost .panel.grid2 > .field:nth-child(5){grid-column:1;grid-row:3}
#quotationFormHost .panel.grid2 > .field:nth-child(6){grid-column:2;grid-row:3}
#quotationFormHost .panel.grid2 > #directSalesField{grid-column:1;grid-row:4}
#quotationFormHost .panel.grid2 > .field:last-child{grid-column:2;grid-row:2}
/* Keep the shared QA entry table inside the available page width. */
#quotationFormHost table:has(>tbody#rows){width:100%!important;min-width:0!important;table-layout:fixed}
#quotationFormHost table:has(>tbody#rows) th:nth-child(1){width:4%}
#quotationFormHost table:has(>tbody#rows) th:nth-child(2){width:13%}
#quotationFormHost table:has(>tbody#rows) th:nth-child(3){width:32%}
#quotationFormHost table:has(>tbody#rows) th:nth-child(4){width:7%}
#quotationFormHost table:has(>tbody#rows) th:nth-child(5){width:7%}
#quotationFormHost table:has(>tbody#rows) th:nth-child(6){width:11%}
#quotationFormHost table:has(>tbody#rows) th:nth-child(7){width:11%}
#quotationFormHost table:has(>tbody#rows) th:nth-child(8){width:10%}
#quotationFormHost table:has(>tbody#rows) th:nth-child(9){width:5%}
#quotationFormHost #rows td{min-width:0!important;padding:5px 4px}
#quotationFormHost #rows :is(input,select,textarea){width:100%!important;min-width:0!important;max-width:100%!important}
#quotationFormHost #rows .desc{min-width:0!important}
#quotationFormHost #rows tr > td:nth-child(2) .skuSearch{width:100%!important;min-width:0!important;max-width:100%!important;margin-left:0!important;margin-right:0!important;text-align:left!important;font-variant-numeric:tabular-nums}
@media(max-width:900px){
  #quotationFormHost .panel.grid2 > .field:not(.qa-auto-number-field){grid-column:1!important;grid-row:auto!important}
  #quotationFormHost .panel.grid2 > .field:nth-child(3){order:1}
  #quotationFormHost .panel.grid2 > .field:nth-child(4){order:2}
  #quotationFormHost .panel.grid2 > .field:nth-child(5){order:3}
  #quotationFormHost .panel.grid2 > #directSalesField{order:4}
  #quotationFormHost .panel.grid2 > .field:nth-child(2){order:5}
  #quotationFormHost .panel.grid2 > .field:last-child{order:6}
  #quotationFormHost .panel.grid2 > .field:nth-child(6){order:7}
}

/* V112: Move the existing Sales Revision search control to the right. Do not change its text, behavior, width, or any locked content. */
#revision .v104-revision-searchbar { display:flex!important; justify-content:flex-end!important; width:100%!important; }
#revision #v104RevisionSearch { margin-left:auto!important; margin-right:0!important; }

#cnr-live-dashboard-sqr .cnr-live-sqr-table{table-layout:fixed;min-width:560px}#cnr-live-dashboard-sqr .cnr-live-sqr-table th,#cnr-live-dashboard-sqr .cnr-live-sqr-table td{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}#cnr-live-dashboard-sqr .cnr-live-sqr-table th:nth-child(1){width:18%}#cnr-live-dashboard-sqr .cnr-live-sqr-table th:nth-child(2){width:24%}#cnr-live-dashboard-sqr .cnr-live-sqr-table th:nth-child(3){width:38%}#cnr-live-dashboard-sqr .cnr-live-sqr-table th:nth-child(4){width:20%}#cnr-live-dashboard-sqr .cnr-live-sqr-table .status{display:inline-block;white-space:nowrap;max-width:100%;box-sizing:border-box;overflow:hidden;text-overflow:ellipsis}
#dashboard .cnr-admin-latest-qa{width:100%;table-layout:fixed}#dashboard .cnr-admin-latest-qa th,#dashboard .cnr-admin-latest-qa td{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}#dashboard .cnr-admin-latest-qa th:nth-child(1){width:28%}#dashboard .cnr-admin-latest-qa th:nth-child(2){width:50%}#dashboard .cnr-admin-latest-qa th:nth-child(3){width:22%}#dashboard .cnr-admin-latest-qa .status{white-space:nowrap;display:inline-block;max-width:100%;box-sizing:border-box;overflow:hidden;text-overflow:ellipsis}#dashboard .cnr-admin-latest-qa th:nth-child(1){width:20%}#dashboard .cnr-admin-latest-qa th:nth-child(2){width:29%}#dashboard .cnr-admin-latest-qa th:nth-child(3){width:23%}#dashboard .cnr-admin-latest-qa th:nth-child(4){width:13%}#dashboard .cnr-admin-latest-qa th:nth-child(5){width:15%}#cnr-live-dashboard-sqr .cnr-admin-sqr-sales{min-width:0;width:100%}#cnr-live-dashboard-sqr .cnr-admin-sqr-sales th:nth-child(1){width:16%}#cnr-live-dashboard-sqr .cnr-admin-sqr-sales th:nth-child(2){width:22%}#cnr-live-dashboard-sqr .cnr-admin-sqr-sales th:nth-child(3){width:28%}#cnr-live-dashboard-sqr .cnr-admin-sqr-sales th:nth-child(4){width:14%}#cnr-live-dashboard-sqr .cnr-admin-sqr-sales th:nth-child(5){width:20%}#dashboard.cnr-admin-qa-charts .graphgrid{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:16px!important;width:100%;margin-top:16px}#dashboard.cnr-admin-qa-charts .graphgrid>.panel{min-width:0;width:auto;box-sizing:border-box;min-height:320px}#dashboard.cnr-admin-qa-charts .graphgrid>.panel>h3{margin:-15px -15px 12px;padding:12px 15px;background:linear-gradient(90deg,#dff4ff,#e7fbf5);border-radius:17px 17px 0 0}#dashboard.cnr-admin-qa-charts .cnr-qa-chart-total{font-size:28px;font-weight:700;color:#153653;margin:14px 0 2px;font-variant-numeric:tabular-nums}#dashboard.cnr-admin-qa-charts .cnr-qa-chart-caption{color:#6d8493;font-size:12px;margin:3px 0 12px}#dashboard.cnr-admin-qa-charts .cnr-qa-month-chart{display:grid;gap:12px;margin-top:16px}#dashboard.cnr-admin-qa-charts .cnr-qa-month-row{display:grid;grid-template-columns:62px minmax(0,1fr) 110px;gap:12px;align-items:center;font-size:12px;color:#38566d}#dashboard.cnr-admin-qa-charts .cnr-qa-month-track{height:16px;background:#eef4f8;border-radius:5px;overflow:hidden}#dashboard.cnr-admin-qa-charts .cnr-qa-month-bar{height:100%;border-radius:5px;background:#347bb7}#dashboard.cnr-admin-qa-charts .cnr-qa-month-value{text-align:right;white-space:nowrap;font-variant-numeric:tabular-nums}@media(max-width:1100px){#dashboard.cnr-admin-qa-charts .graphgrid{grid-template-columns:1fr!important}}#dashboard.cnr-admin-qa-charts .cnr-qa-month-chart{grid-template-columns:repeat(6,minmax(0,1fr));gap:8px}#dashboard.cnr-admin-qa-charts .cnr-qa-month-row{display:flex;flex-direction:column;gap:8px;min-width:0;font-size:11px}#dashboard.cnr-admin-qa-charts .cnr-qa-month-track{height:160px;width:100%;max-width:48px;display:flex;align-items:flex-end}#dashboard.cnr-admin-qa-charts .cnr-qa-month-bar{width:100%}#dashboard.cnr-admin-qa-charts .cnr-qa-month-value{font-size:10px;text-align:center}
body:has(#rs.active):not(:has(#ra.active)) .page button.cnr-sales-search-icon{font-size:0!important;gap:0!important;min-width:44px;justify-content:center!important}body:has(#rs.active):not(:has(#ra.active)) .page button.cnr-sales-search-icon>*{display:none!important}body:has(#rs.active):not(:has(#ra.active)) .page button.cnr-sales-search-icon::before{content:"🔍";font-family:"Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",sans-serif;font-size:17px!important;line-height:1}
[data-report-field]{box-sizing:border-box;width:100%;height:42px;border:1px solid #b6d9e9;border-radius:9px;background:#e3f4ff;color:#26465c;padding:8px 12px;font:inherit}
#sqrFormHost .quick,#quotationFormHost .quick{width:100%!important}#sqrFormHost .quick textarea#quick,#quotationFormHost .quick textarea#quick{width:100%!important;max-width:none!important;min-height:190px!important;resize:vertical}#sqrRows textarea.desc,#quotationFormHost #rows textarea.desc{min-width:280px;min-height:44px;overflow-y:hidden;box-sizing:border-box;resize:vertical}.cost.locked{background:#eef2f5;color:#617080}.quick-choice{min-width:380px!important;max-width:520px}.cnr-sqr-add-item-actions{display:flex;justify-content:flex-start;margin:12px 0 4px}.cnr-sqr-add-item-actions .btn{min-width:140px}#quickConfirmModal.hidden{display:none!important}#quickConfirmModal:not(.hidden){position:fixed;inset:0;background:rgba(9,30,66,.45);z-index:12000;display:flex;align-items:flex-start;justify-content:center;padding:24px;overflow:auto}#quickConfirmModal .modalbox{width:min(1050px,100%);background:#fff;border-radius:12px;box-shadow:0 18px 55px rgba(0,0,0,.25);overflow:hidden}#quickConfirmModal .modalhead{background:#1877f2;color:#fff;padding:15px 20px;display:flex;justify-content:space-between;align-items:center;font-size:19px;font-weight:800}#quickConfirmModal .modalbody{padding:18px}#quickConfirmModal .x{border:0;background:transparent;color:#fff;font-size:24px;cursor:pointer}#quickConfirmModal .status-ok{color:#159447;font-weight:700}#quickConfirmModal .status-warn{color:#b26a00;font-weight:700}#sqrRows .cost.cnr-cost-ok,#quotationFormHost #rows .cost.cnr-cost-ok{background:#e9f8ee!important;border:2px solid #27a65a!important;color:#176a39!important}#sqrRows .cost.cnr-cost-loss,#quotationFormHost #rows .cost.cnr-cost-loss{background:#fff0f0!important;border:2px solid #df3e3e!important;color:#a21f1f!important}.cnr-cost-warning{margin-top:4px;color:#c62828;font-size:12px;font-weight:700;line-height:1.25}tr[data-package-component="1"]{background:#fbfdff}tr[data-package-component="1"] .cnr-package-no-price input{display:none!important}tr[data-package-component="1"] .cnr-package-no-price::after{content:"—";display:block;text-align:center;color:#7b8795;font-weight:700}tr[data-package-component="1"] .skuSearch,tr[data-package-component="1"] textarea,tr[data-package-component="1"] select,tr[data-package-component="1"] .qty{background:#f6f9fc!important;color:#40556d}.cnr-quick-detail-row{background:#f8fbff}.cnr-quick-detail-row td{border-top:1px dashed #c9d8e8}.cnr-quick-detail-row td:nth-child(2){padding-left:18px;font-weight:600;color:#40556d}.cnr-quick-detail-row .cnr-detail-choice{min-width:430px!important}

   .cnr-production-master{margin-top:12px}.cnr-prod-searchbar{display:flex;gap:10px;align-items:flex-end;flex-wrap:wrap}
   #cnr-production-products .cnr-prod-filter-toggle,#cnr-production-products .cnr-prod-refresh{display:none!important}
   #cnr-production-products .cnr-prod-grid{margin-top:18px}
   #cnr-production-products .cnr-prod-grid th:nth-child(1),#cnr-production-products .cnr-prod-grid td:nth-child(1){min-width:120px}
   #cnr-production-products .cnr-prod-grid th:nth-child(2),#cnr-production-products .cnr-prod-grid td:nth-child(2){width:58%;min-width:430px;white-space:normal!important;line-height:1.45}
   #cnr-production-products .cnr-prod-grid th:nth-child(3),#cnr-production-products .cnr-prod-grid td:nth-child(3){min-width:90px}
   #cnr-production-products .cnr-prod-grid th:nth-child(4),#cnr-production-products .cnr-prod-grid td:nth-child(4){width:140px;min-width:140px;padding-left:26px!important;padding-right:26px!important;text-align:center!important}
   #cnr-production-products .cnr-prod-grid th:nth-child(5),#cnr-production-products .cnr-prod-grid td:nth-child(5){min-width:170px;padding-left:24px!important}
   .cnr-prod-searchbar label{display:grid;gap:12px;flex:1;min-width:280px;font-weight:700}.cnr-prod-search{width:100%;padding:11px 12px;border:1px solid #bfd0de;border-radius:9px;font:inherit}
   #customers .cnr-prod-filter-toggle{position:relative!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;width:36px!important;min-width:36px!important;max-width:36px!important;height:34px!important;min-height:34px!important;max-height:34px!important;padding:0!important;gap:0!important;font-size:0!important;line-height:0!important;overflow:hidden!important}
   #customers .cnr-prod-filter-toggle>*{display:none!important}#customers .cnr-prod-filter-toggle::after{content:none!important;display:none!important}#customers .cnr-prod-filter-toggle::before{content:""!important;display:block!important;width:18px!important;height:18px!important;flex:0 0 18px!important;background-color:currentColor!important;-webkit-mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important;mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important}
   .cnr-prod-filterbox[hidden]{display:none!important}.cnr-prod-filterbox{display:flex;gap:12px;align-items:end;flex-wrap:wrap;margin:10px 0;padding:12px;background:#f3f8fc;border:1px solid #d7e5ef;border-radius:10px}.cnr-prod-filterbox label{display:grid;gap:5px;font-weight:700;color:#38566d}.cnr-prod-filterbox select,.cnr-prod-filterbox input{min-width:180px;padding:9px 10px;border:1px solid #bfd0de;border-radius:8px;background:#fff;font:inherit}
   body:has(#ra.active) #customers>.toolbar #cnr-v77-filter-btn,body:has(#rs.active) #customers>.toolbar #cnr-v77-filter-btn,#customers>.toolbar .cnr-prod-duplicate-filter{display:none!important}.cnr-prod-status[hidden]{display:none!important}.cnr-prod-status{margin:10px 0;color:#27627d}.cnr-prod-status[data-error="1"]{color:#a12a20}.cnr-prod-tablewrap{overflow-x:auto;overflow-y:visible}
   .cnr-prod-grid table{width:100%;border-collapse:separate;border-spacing:0}.cnr-prod-grid th,.cnr-prod-grid td{padding:9px;border-bottom:1px solid #e4edf3;text-align:left;white-space:nowrap}
   #cnr-production-customers .cnr-prod-grid{margin-top:18px}#cnr-production-customers .cnr-prod-grid th:nth-child(3),#cnr-production-customers .cnr-prod-grid td:nth-child(3){min-width:180px;padding-right:24px}#cnr-production-customers .cnr-prod-grid th:nth-child(4),#cnr-production-customers .cnr-prod-grid td:nth-child(4){min-width:320px;padding-left:24px}
   #cnr-production-customers .cnr-prod-grid table{table-layout:fixed;width:100%;min-width:0}#cnr-production-customers .cnr-prod-grid :is(th,td){box-sizing:border-box;min-width:0!important;max-width:none;white-space:nowrap!important;overflow:hidden;text-overflow:ellipsis;padding:10px 9px!important;vertical-align:middle;line-height:1.45}#cnr-production-customers .cnr-prod-grid :is(th,td):nth-child(1){width:10%}#cnr-production-customers .cnr-prod-grid :is(th,td):nth-child(2){width:30%}#cnr-production-customers .cnr-prod-grid :is(th,td):nth-child(3){width:18%}#cnr-production-customers .cnr-prod-grid :is(th,td):nth-child(4){width:32%}#cnr-production-customers .cnr-prod-grid :is(th,td):nth-child(5){width:10%}
   :is(#cnr-production-customers,#cnr-production-products) .cnr-prod-grid tbody tr:is(:hover,:focus-within)>td{background:#EAF6FE!important}
   :is(#cnr-production-customers,#cnr-production-products) .cnr-prod-grid tbody tr:is(:hover,:focus-within)>td:first-child{border-radius:12px 0 0 12px!important}
   :is(#cnr-production-customers,#cnr-production-products) .cnr-prod-grid tbody tr:is(:hover,:focus-within)>td:last-child{border-radius:0 12px 12px 0!important}
   .cnr-prod-grid th{position:sticky;top:0;background:#eaf8fb;z-index:1}.cnr-prod-grid tbody tr:hover td{background:#eaf6fe}.cnr-prod-money{text-align:right!important;font-variant-numeric:tabular-nums}.cnr-prod-empty{padding:18px;color:#62778a;text-align:center}
   .cnr-prod-customer-row{cursor:pointer}.cnr-prod-customer-row:focus{outline:2px solid #1688c9;outline-offset:-2px}.cnr-prod-customer-row:focus td{background:#eaf6fe}.cnr-prod-address{min-width:280px;max-width:460px;white-space:normal!important;line-height:1.45}
   .cnr-prod-more{padding:16px;text-align:center;color:#62778a}.cnr-prod-more[hidden]{display:none!important}
   .cnr-prod-modal[hidden]{display:none!important}.cnr-prod-modal{position:fixed;inset:0;z-index:15000;background:rgba(12,31,51,.6);display:flex;align-items:center;justify-content:center;padding:18px}
   .cnr-prod-modalbox{background:#fff;width:min(1120px,100%);max-height:92vh;border-radius:14px;box-shadow:0 22px 70px #0006;overflow:hidden}.cnr-prod-modalhead{display:flex;justify-content:space-between;align-items:center;background:#176fbd;color:#fff;padding:14px 18px}.cnr-prod-modalhead h3{margin:0;font-size:19px}.cnr-prod-modal-close{border:0;background:transparent;color:#fff;font-size:28px;line-height:1;cursor:pointer}
   .cnr-prod-modalbody{padding:18px;overflow:auto;max-height:calc(92vh - 60px)}.cnr-prod-modalbody h4{margin:4px 0 10px;padding:9px 12px;background:#eaf6fe;border-left:4px solid #176fbd;border-radius:7px}.cnr-prod-modalbody section+section{margin-top:18px}.cnr-prod-details{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 30px}.cnr-prod-detail-column{display:grid;align-content:start}.cnr-prod-detail{display:grid;grid-template-columns:minmax(145px,38%) 1fr;gap:10px;padding:8px 3px;border-bottom:1px solid #e8eef3}.cnr-prod-detail b{color:#38566d}.cnr-prod-detail span{white-space:pre-wrap;overflow-wrap:anywhere}.cnr-prod-contact-wrap{overflow:auto}.cnr-prod-contact-wrap table{width:100%;border-collapse:collapse}.cnr-prod-contact-wrap th,.cnr-prod-contact-wrap td{padding:8px;border-bottom:1px solid #e4edf3;text-align:left;white-space:nowrap}.cnr-prod-contact-wrap th{background:#f2f8fc}.cnr-prod-modal-loading{padding:26px;text-align:center}.cnr-prod-modal-error{padding:18px;color:#a12a20;background:#fff1f0;border-radius:8px}
   .cnr-prod-section-head{display:flex;align-items:center;justify-content:space-between;gap:10px}.cnr-prod-section-head h4{flex:1;margin-right:8px}.cnr-prod-contact-form{margin:10px 0 14px;padding:12px;background:#f7fbfe;border:1px solid #d7e5ef;border-radius:10px}.cnr-prod-contact-form[hidden]{display:none!important}.cnr-prod-contact-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.cnr-prod-contact-fields label{display:grid;gap:5px;font-weight:700;color:#38566d}.cnr-prod-contact-fields input,.cnr-prod-contact-fields textarea,.cnr-prod-customer-note,.cnr-prod-edit-grid input,.cnr-prod-edit-grid textarea,.cnr-prod-edit-contact-table input,.cnr-prod-edit-contact-table textarea{width:100%;box-sizing:border-box;padding:9px 10px;border:1px solid #bfd0de;border-radius:8px;background:#fff;font:inherit}.cnr-prod-contact-note{grid-column:1/-1}.cnr-prod-form-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:10px}.cnr-prod-contact-status,.cnr-prod-note-status,.cnr-prod-edit-status{font-size:12px;color:#27627d}.cnr-prod-note-readonly{min-height:56px;padding:11px 12px;white-space:pre-wrap;background:#f7fbfe;border:1px solid #d7e5ef;border-radius:9px}.cnr-prod-edit-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px 18px}.cnr-prod-edit-grid label{display:grid;gap:6px;font-weight:700;color:#38566d}.cnr-prod-edit-grid label:has(textarea){grid-column:1/-1}.cnr-prod-edit-contact-table{min-width:900px}.cnr-prod-edit-contact-table input{min-width:130px}.cnr-prod-edit-contact-table textarea{min-width:180px}.cnr-prod-global-actions{display:flex;align-items:center;justify-content:flex-end;gap:9px;flex-wrap:wrap;margin-top:18px;padding-top:14px;border-top:1px solid #dce8f1}
   @media(max-width:720px){.cnr-prod-details,.cnr-prod-contact-fields,.cnr-prod-edit-grid{grid-template-columns:1fr}.cnr-prod-contact-note,.cnr-prod-edit-grid label:has(textarea){grid-column:auto}.cnr-prod-modal{padding:8px}.cnr-prod-modalbox{max-height:96vh}.cnr-prod-modalbody{max-height:calc(96vh - 60px)}}
  
#modal:has(.cnr-live-qa-more) .box{width:min(420px,calc(100vw - 32px))!important;height:auto!important;min-height:0!important;max-height:90vh!important}#modal:has(.cnr-live-qa-more) #mb{height:auto!important;min-height:0!important}#modal .cnr-live-qa-more>.btn{display:block;width:100%;min-height:38px;margin:0;text-align:left}#cnr-qa-list table{border-collapse:separate!important;border-spacing:0!important}#cnr-qa-list tbody tr:hover>td,#cnr-qa-list tbody tr:focus-within>td{background:#EAF6FE!important}#cnr-qa-list tbody tr:hover>td:first-child,#cnr-qa-list tbody tr:focus-within>td:first-child{border-radius:12px 0 0 12px!important}#cnr-qa-list tbody tr:hover>td:last-child,#cnr-qa-list tbody tr:focus-within>td:last-child{border-radius:0 12px 12px 0!important}#cnr-qa-list td.cnr-qa-pdf-number{cursor:pointer;color:#1678b8}#cnr-qa-list td.cnr-qa-pdf-number:hover,#cnr-qa-list td.cnr-qa-pdf-number:focus-visible{color:#075b91;text-decoration:underline;outline:2px solid #75c2ed;outline-offset:-2px}#cnr-qa-list tbody tr{cursor:pointer}#cnr-qa-list tbody tr .actions{cursor:default}#cnr-qa-list th:nth-child(3),#cnr-qa-list td:nth-child(3){text-align:center!important}#cnr-qa-list-filter-menu[hidden]{display:none!important}#cnr-qa-list-filter-menu{position:absolute;z-index:30;right:0;top:calc(100% + 5px);width:245px;padding:14px;display:grid;gap:9px;background:#fff;border:1px solid #c9ddeb;border-radius:10px;box-shadow:0 12px 30px #24425b33}#cnr-qa-list-filter-menu label{display:grid;gap:4px;color:#284761;font-size:13px}#cnr-qa-list-filter-menu select,#cnr-qa-list-filter-menu input{box-sizing:border-box;width:100%;padding:8px;border:1px solid #d5e0e9;border-radius:7px;background:#fff}body:has(#rs.active) #cnr-qa-list tbody tr:hover>td:last-child,body:has(#rs.active) #cnr-qa-list tbody tr:focus-within>td:last-child{background:transparent!important;border-radius:0!important}body:has(#rs.active) #cnr-qa-list tbody tr:hover>td:nth-last-child(2),body:has(#rs.active) #cnr-qa-list tbody tr:focus-within>td:nth-last-child(2){border-radius:0 10px 10px 0!important}#modal:has(.cnr-live-qa-edit) .box{width:min(540px,calc(100vw - 32px))!important;height:auto!important;min-height:0!important;max-height:90vh!important}#modal:has(.cnr-live-qa-edit) #mb{height:auto!important;min-height:0!important}#modal .cnr-live-qa-edit>.btn{justify-self:start!important;width:max-content!important;min-width:0!important;max-width:100%!important;margin:0!important;padding:9px 14px!important}#cnr-qa-list .cnr-qa-no-sqr{display:block;width:max-content;max-width:100%;margin-top:5px;padding:2px 7px;border-radius:8px;background:#eef4f8;color:#52657a;font-size:11px;white-space:nowrap}#cnr-qa-list span.status.cnr-b79-status[data-cnr-b79-status="draft"]{background:#FFF0C9!important;color:#875C00!important}#cnr-qa-list span.status.cnr-b79-status[data-cnr-b79-status="sent"]{background:#DDF5E7!important;color:#176847!important}#cnr-qa-list table{table-layout:fixed;width:100%;min-width:900px}#cnr-qa-list th,#cnr-qa-list td{overflow-wrap:anywhere}#cnr-qa-list th:nth-child(3),#cnr-qa-list td:nth-child(3){text-align:center!important}#cnr-qa-list table[data-cnr-columns="admin"] td.cnr-qa-pdf-number:hover,#cnr-qa-list table[data-cnr-columns="admin"] td.cnr-qa-pdf-number:focus-visible{outline:none!important;box-shadow:none!important;text-decoration:none!important}#cnr-qa-list table[data-cnr-columns="admin"] td:last-child{background:transparent!important;border-radius:0!important}#cnr-qa-list table[data-cnr-columns="admin"] tbody tr:hover>td:nth-last-child(2),#cnr-qa-list table[data-cnr-columns="admin"] tbody tr:focus-within>td:nth-last-child(2){border-radius:0 12px 12px 0!important}#cnr-qa-list table[data-cnr-columns="admin"] td:first-child{white-space:nowrap}#cnr-qa-list table[data-cnr-columns="admin"] th{background:#eaf8fb!important;border-radius:0!important}#allqa #cnr-qa-list table[data-cnr-columns="admin"] :is(th,td){text-align:left!important;vertical-align:middle;white-space:nowrap;padding:10px 7px;box-sizing:border-box}#cnr-qa-list table[data-cnr-columns="admin"] td:not(:last-child){overflow:hidden;text-overflow:ellipsis}#cnr-qa-list table[data-cnr-columns="admin"] td.actions .b77-actions-wrap{display:inline-flex;align-items:center;justify-content:flex-start;margin:0}#allqa #cnr-qa-list table[data-cnr-columns="admin"] td.actions{display:table-cell!important;vertical-align:middle!important;margin:0!important;padding:10px 7px!important}#cnr-qa-list table[data-cnr-columns="sales"] :is(th,td):nth-child(4){text-align:center;vertical-align:middle;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}#allqa #cnr-qa-list table[data-cnr-columns="sales"] :is(th,td){text-align:left!important;vertical-align:middle!important;white-space:nowrap;padding:10px 7px;box-sizing:border-box}#allqa #cnr-qa-list table[data-cnr-columns="sales"] tbody td:not(:last-child){overflow:hidden;text-overflow:ellipsis;height:54px}#allqa #cnr-qa-list table[data-cnr-columns="sales"] td.actions{display:table-cell!important;vertical-align:middle!important;margin:0!important;padding:10px 7px!important}#allqa #cnr-qa-list table[data-cnr-columns="sales"] td.actions .b77-actions-wrap{display:inline-flex;align-items:center;justify-content:center;margin:0}

/* Approved sidebar background starts in the first stylesheet. The rule below holds even when later plugins run. */
.app > aside.side {background:#030164!important}
/* Admin New Quotation: remove remaining embedded .main 22px padding down to 8px; no image resize. */
body:has(#ra.active) #newqa>.title{margin-bottom:0!important}
body:has(#ra.active) #newqa #quotationFormHost > main.main {padding-top:8px!important}
/* QA search stays visually empty even during any legacy placeholder mutations. */
#allqa > .toolbar > input.search::placeholder{color:transparent!important;opacity:0!important}
/* Admin SQR: never paint invalid/legacy table while page or deferred renderer is preparing. */
body:has(#ra.active) #sqr #sqrMainTable:not([data-cnr-r4-ready="1"]){visibility:hidden!important}
body:has(#ra.active) #sqr #sqrMainTable:not([data-cnr-live-source="production"]):has(tr:first-child > th:nth-child(7)),
body:has(#ra.active) #sqr #sqrMainTable:not([data-cnr-live-source="production"]):has(tr[data-sqr-status] > td:nth-child(7)){visibility:hidden!important}
/* Customer Filter: hide both the legacy text/triangle and any injected SVG, show one funnel only. */
body:has(#ra.active) #customers #cnr-v77-filter-btn{
 position:relative!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;
 width:36px!important;min-width:36px!important;max-width:36px!important;
 height:34px!important;min-height:34px!important;max-height:34px!important;
 padding:0!important;gap:0!important;font-size:0!important;line-height:0!important;overflow:hidden!important
}
body:has(#ra.active) #customers #cnr-v77-filter-btn > *{display:none!important}
body:has(#ra.active) #customers #cnr-v77-filter-btn::after{content:none!important;display:none!important}
body:has(#ra.active) #customers #cnr-v77-filter-btn::before{
 content:""!important;display:block!important;width:18px!important;height:18px!important;flex:0 0 18px!important;
 background-color:currentColor!important;
 -webkit-mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important;
 mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important
}


/* The authenticated Production browser owns the only visible customer filter.
   Hide legacy toolbar filters at first paint, before role/navigation scripts run. */
#customers > .toolbar > #cnr-v77-filter-btn,
#customers > .toolbar > button.v32-filter-btn,
#customers > .toolbar > button.cnr-b83-one-filter,
#customers > .toolbar > input.search,
#customers > .toolbar > input.search + button.btn,
body:has(#ra.active) #customers .toolbar > button.v32-filter-btn:not(#cnr-v77-filter-btn),
body:has(#ra.active) #customers .toolbar > button.cnr-b83-one-filter:not(#cnr-v77-filter-btn){display:none!important}


body:not(.cnr3b-authed)>*:not(#cnr-step3b-gate):not(script):not(style){visibility:hidden!important;pointer-events:none!important}
#cnr-step3b-gate{position:fixed;inset:0;z-index:2147483000;overflow:auto;background:#f4f9fc;display:flex;align-items:center;justify-content:center;padding:22px;font-family:Tahoma,Arial,sans-serif;color:#183a50}
#cnr-step3b-gate[hidden]{display:none!important}
#cnr-step3b-gate .cnr3b-card{width:min(440px,100%);border-radius:16px;border:1px solid #d3e4ed;background:white;padding:26px;box-shadow:0 10px 34px #17395516}
#cnr-step3b-gate h1{margin:0 0 8px;font-size:21px;color:#123454}
#cnr-step3b-gate p{font-size:13px;color:#587286;line-height:1.7}
#cnr-step3b-gate label{display:block;margin-top:14px;margin-bottom:5px;font-weight:700;font-size:13px}
#cnr-step3b-gate input{display:block;width:100%;padding:11px 12px;min-height:41px;box-sizing:border-box;border:1px solid #aac4d5;border-radius:10px}
#cnr-step3b-gate button{border:0;border-radius:10px;background:#086caa;color:white;padding:12px 18px;margin-top:17px;font-weight:bold;cursor:pointer}
#cnr-step3b-gate button.cnr3b-secondary{background:transparent;color:#086caa;border:1px solid #8dbbd2;margin-left:8px}
#cnr-step3b-gate .cnr3b-actions{display:flex;flex-wrap:wrap;align-items:center;gap:8px}
#cnr-step3b-gate .cnr3b-actions button{margin-left:0}
#cnr-step3b-reset[hidden]{display:none!important}
#cnr-step3b-gate .cnr3b-help{margin:8px 0 0;font-size:12px;color:#6c8190}
#cnr-step3b-gate button:disabled{opacity:.6;cursor:wait}
#cnr-step3b-status{font-size:13px;margin-top:12px;min-height:22px}
#cnr-step3b-status[data-error="1"]{color:#ae2b34}
#cnr-step3b-logout{display:none!important}
body.cnr3b-authed #cnr-step3b-logout{display:block!important;position:fixed;right:14px;bottom:13px;z-index:60;border-radius:10px;padding:8px 13px;border:1px solid #abcddf;background:#f1f9ff;color:#13516f;font-size:12px;cursor:pointer}
#cnr-step3b-identity{display:none;position:fixed;right:14px;bottom:56px;z-index:60;font-size:11px;padding:5px 8px;border-radius:8px;color:#214d67;background:#f7fcffdf}
body.cnr3b-authed #cnr-step3b-identity{display:block}
/* Role comes from the signed-in account; preserve hidden IDs for menu logic. */
body.cnr3b-authed .side > .role{display:none!important}


body:has(#ra.active) #quotationFormHost .tablewrap:has(#rows){width:100%!important;max-width:100%!important;overflow:visible!important;box-sizing:border-box}
body:has(#ra.active) #quotationFormHost table:has(#rows){width:100%!important;max-width:100%!important;min-width:0!important;table-layout:fixed!important}
body:has(#ra.active) #quotationFormHost table:has(#rows) :is(th,td){box-sizing:border-box!important;min-width:0!important;padding:5px 3px!important;white-space:normal!important;overflow-wrap:anywhere}
body:has(#ra.active) #quotationFormHost #rows :is(input,select,textarea,button){box-sizing:border-box!important;width:100%!important;max-width:100%!important;min-width:0!important;margin:0!important;padding:6px 3px!important}
body:has(#ra.active) #quotationFormHost #rows .desc{min-width:0!important;resize:vertical}


body:has(#ra.active) #quotationFormHost input[placeholder="ค้นหาลูกค้า"]::placeholder{color:#757575;opacity:1}
body:has(#ra.active) #quotationFormHost #directSales:has(option[value=""]:checked){color:#757575}
body:has(#ra.active) #quotationFormHost #directSales option:not([value=""]){color:#000}


body:has(#ra.active) #sqr #sqrMainTable[data-cnr-live-source="production"] tr>td.actions.cnr-b83-sqr-actions{display:table-cell!important;width:1%;text-align:right!important;vertical-align:middle;white-space:nowrap;padding-right:12px}
body:has(#ra.active) #sqr #sqrMainTable[data-cnr-live-source="production"] .cnr-b83-sqr-actions-inner{display:inline-flex!important;justify-content:flex-end;flex-wrap:nowrap!important;white-space:nowrap;gap:7px}


body:has(#ra.active) #dashboard .graphgrid{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:16px!important;width:100%;margin-top:16px}
body:has(#ra.active) #dashboard .graphgrid>.panel:nth-child(-n+2){min-width:0;width:auto;box-sizing:border-box;min-height:320px}
body:has(#ra.active) #dashboard .graphgrid>.panel:nth-child(-n+2)>:not(h3):not([data-live-qa]){display:none!important}
body:has(#ra.active) #dashboard .graphgrid>.panel>h3{margin:-15px -15px 12px;padding:12px 15px;background:linear-gradient(90deg,#dff4ff,#e7fbf5);border-radius:17px 17px 0 0}
@media(max-width:1100px){body:has(#ra.active) #dashboard .graphgrid{grid-template-columns:1fr!important}}


body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable[data-cnr-live-source="production"]{visibility:visible!important;table-layout:fixed;width:100%;min-width:0}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable[data-cnr-live-source="production"] tr>:nth-child(1){width:10%!important;min-width:0!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:left!important;text-indent:0!important}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable[data-cnr-live-source="production"] tr>:nth-child(2){width:13%!important;min-width:0!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:left!important;text-indent:0!important}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable[data-cnr-live-source="production"] tr>:nth-child(3){width:28%!important;min-width:0!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:left!important;text-indent:0!important}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable[data-cnr-live-source="production"] tr>:nth-child(4){width:16%!important;min-width:0!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:left!important;text-indent:0!important}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable[data-cnr-live-source="production"] tr>:nth-child(5){width:13%!important;min-width:0!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:left!important;text-indent:0!important}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable[data-cnr-live-source="production"] tr>:nth-child(6){width:10%!important;min-width:0!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:left!important;text-indent:0!important}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable[data-cnr-live-source="production"] tr>:nth-child(7){width:10%!important;min-width:0!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:left!important;text-indent:0!important}
body:has(#rs.active) #sqr #sqrMainTable[data-cnr-live-source="production"] td.actions{display:table-cell!important;vertical-align:middle;text-align:right!important}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable[data-cnr-live-source="production"] tr>:is(th,td){box-sizing:border-box;padding:12px 9px!important;vertical-align:middle}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable[data-cnr-live-source="production"] td.actions{padding-right:12px!important;text-align:right!important}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable[data-cnr-live-source="production"] td.actions .cnr-b83-sqr-actions-inner{display:inline-flex!important;justify-content:flex-end!important;align-items:center;gap:6px;width:100%;margin:0!important;flex-wrap:wrap}
body:has(#rs.active) #revision>:not(.title):not(#cnr-live-revision){display:none!important}
body:has(#ra.active) #cnr-live-revision{display:none!important}


body:has(#rs.active):not(:has(#ra.active)) #dashboard table.cnr-sales-latest-qa{width:100%!important;min-width:0!important;max-width:100%!important;table-layout:fixed!important}
body:has(#rs.active):not(:has(#ra.active)) #dashboard table.cnr-sales-latest-qa :is(th,td){white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;vertical-align:middle!important;text-align:left!important;padding:11px 6px!important;font-size:12px!important;display:table-cell!important;visibility:visible!important;box-sizing:border-box;word-break:normal!important;overflow-wrap:normal!important}
body:has(#rs.active):not(:has(#ra.active)) #dashboard table.cnr-sales-latest-qa tr>:nth-child(1){width:100px!important}
body:has(#rs.active):not(:has(#ra.active)) #dashboard table.cnr-sales-latest-qa tr>:nth-child(2){width:calc(50% - 95px)!important}
body:has(#rs.active):not(:has(#ra.active)) #dashboard table.cnr-sales-latest-qa tr>:nth-child(3){width:calc(50% - 95px)!important}
body:has(#rs.active):not(:has(#ra.active)) #dashboard table.cnr-sales-latest-qa tr>:nth-child(4){width:90px!important}

body:has(#rs.active):not(:has(#ra.active)) #dashboard table.cnr-sales-latest-qa tr>:last-child{overflow:visible!important;text-overflow:clip!important}
body:has(#rs.active):not(:has(#ra.active)) #dashboard table.cnr-sales-latest-qa .status{display:inline-block!important;visibility:visible!important;white-space:nowrap!important;font-size:11px!important;padding:4px 6px!important;max-width:none!important}


/* V30 review layer */
#dashboard .latest-grid>.panel{min-height:300px;display:flex;flex-direction:column}
#dashboard .latest-grid>.panel>div:last-child{flex:1}
#dashboard .graphgrid{margin-top:16px}
#dashboard.v30-sales #kpis{display:grid!important;grid-template-columns:repeat(2,minmax(230px,320px))!important;justify-content:center!important;gap:20px!important}
#dashboard.v30-sales #kpis .card{width:100%}
.deposit-head{display:flex!important;justify-content:space-between!important;align-items:center!important;gap:12px}
.deposit-row{display:grid!important;grid-template-columns:90px 120px minmax(220px,1fr) auto!important;gap:10px!important;align-items:center!important}
.deposit-percent{display:flex!important;align-items:center!important;justify-content:flex-end!important;gap:5px!important}
.deposit-percent input{width:85px!important;text-align:right!important}
.v30-report-grid{display:grid;grid-template-columns:repeat(3,minmax(160px,1fr));gap:12px;margin:12px 0}
.v30-metric{border:1px solid #dbe7ef;border-radius:14px;padding:14px;background:#fff}
.v30-metric b{display:block;font-size:24px;margin-top:4px;color:#0f172a}
.v30-subtle{font-size:13px;color:#64748b}
#sqr .sales-active-note{display:none!important}
@media(max-width:800px){#dashboard.v30-sales #kpis{grid-template-columns:1fr!important}.deposit-row{grid-template-columns:1fr!important}.v30-report-grid{grid-template-columns:1fr!important}}


/* V31 refinement layer */
#dashboard.v30-sales #kpis{grid-template-columns:repeat(4,minmax(170px,1fr))!important;max-width:100%!important;gap:14px!important}
#dashboard.v30-sales .graphgrid{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:16px!important;width:100%!important;overflow:hidden!important}
#dashboard.v30-sales .graphgrid>.panel{min-width:0!important;width:auto!important;overflow:hidden!important}
#dashboard.v30-sales .graph{max-width:100%!important;overflow:hidden!important}
#sqr .v31-filter-row input,#sqr .v31-filter-row select{width:100%;min-width:90px;box-sizing:border-box;padding:7px 8px;border:1px solid #d8e3ec;border-radius:8px;background:#fff}
#sqr .v31-filter-row.hide{display:none!important}
#sqrMainTable td.actions{display:flex;align-items:center;gap:7px;white-space:nowrap}
#sqrMainTable .v31-cancel{margin-left:auto!important}
/* Admin SQR (8 columns): keep View / Cancel as a compact, rightmost pair.
   Sales SQR (6 columns) and every other table keep their original layout. */
#sqrMainTable:has(tr:first-child>th:nth-child(8)) th:nth-last-child(-n+2),
#sqrMainTable:has(tr:first-child>th:nth-child(8)) tr[data-sqr-status]>td:nth-last-child(-n+2){
  width:1%;white-space:nowrap;text-align:right;padding-left:4px;padding-right:4px;
}
#sqrMainTable:has(tr:first-child>th:nth-child(8)) tr[data-sqr-status]>td.actions{
  display:table-cell!important;vertical-align:middle;text-align:right;
}
#sqrMainTable:has(tr:first-child>th:nth-child(8)) tr[data-sqr-status]>td:nth-last-child(-n+2) .btn{
  white-space:nowrap;
}
#sqrMainTable:has(tr:first-child>th:nth-child(8)) .v31-cancel{margin-left:0!important}
/* Sales SQR only: keep View immediately before Cancel at the right edge. */
#sqrMainTable:has(tr:first-child>th:nth-child(6):last-child) tr[data-sqr-status]>td.actions{justify-content:flex-end;flex-wrap:nowrap}
#sqrMainTable:has(tr:first-child>th:nth-child(6):last-child) .v31-cancel{margin-left:0!important}

.v31-more-menu{display:flex;flex-direction:column;align-items:stretch;gap:8px;min-width:260px}
.v31-more-menu .btn{width:100%;text-align:left;justify-content:flex-start}
#allqa .v31-sqr-again-cell{white-space:nowrap}
#allqa .v31-sqr-again-cell .btn{white-space:nowrap}
.v31-pdf-frame{width:100%;height:72vh;border:1px solid #dbe5ec;border-radius:10px;background:#fff}
.v31-upload-btn{display:inline-flex;align-items:center;gap:6px}
@media(max-width:1000px){#dashboard.v30-sales #kpis{grid-template-columns:repeat(2,minmax(180px,1fr))!important}}
@media(max-width:760px){#dashboard.v30-sales #kpis,#dashboard.v30-sales .graphgrid{grid-template-columns:1fr!important}}


/* V32 consistency patch */
.v32-filter-row input,.v32-filter-row select,#sqr .v31-filter-row input,#sqr .v31-filter-row select{width:100%;min-width:88px;box-sizing:border-box;padding:8px 9px;border:1px solid #b8c9d6;border-radius:8px;background:#fff;min-height:36px;color:#0f172a}
.v32-filter-row.hide,#sqr .v31-filter-row.hide{display:none!important}
#allqa td.actions,#allqa th:last-child{text-align:right;white-space:nowrap}
#allqa td.actions{display:flex;justify-content:flex-end;gap:6px;align-items:center}
#allqa .v31-sqr-again-cell{text-align:right;white-space:nowrap}
.v32-other-input.hidden{display:none!important}
#customers .v32-filter-row td:last-child,#allqa .v32-filter-row td:last-child{min-width:1px}


/* V33 approved review changes only */
#sqrFormHost .section,#quotationFormHost .section{background:#dceff8!important;border-radius:9px!important;padding:9px 12px!important;margin-top:14px!important}
.v33-total{margin-left:auto;font-weight:800;padding:5px 10px;border-radius:9px;background:#fff3cd;color:#8a5a00}.v33-total.ok{background:#dcfce7;color:#166534}.v33-total.bad{background:#fee2e2;color:#991b1b}
#revision .v33-history{display:none}#revision.v33-searching .v33-history{display:table-row}
#revision .toolbar{margin-bottom:12px}
#allqa td.actions,#allqa th:last-child{text-align:right!important}


#revision .v34-filter-row{display:none}#revision .v34-filter-row.show{display:table-row}
#revision .v34-filter-row input,#revision .v34-filter-row select{width:100%;box-sizing:border-box;padding:8px;border:1px solid #b8c9d6;border-radius:8px;background:#fff}
.v34-report-filters{display:grid;grid-template-columns:repeat(2,minmax(220px,1fr));gap:12px;margin-bottom:14px}.v34-report-actions{display:flex;gap:8px;align-items:end}.v34-report-table{margin-top:14px}
@media(max-width:800px){.v34-report-filters{grid-template-columns:1fr}}


/* V35: requested consistency fixes only */
#sqrFormHost .optionrow .smallnum,#quotationFormHost .optionrow .smallnum{width:72px!important;max-width:72px!important;min-width:72px!important;flex:0 0 72px!important}
.v35-search-wrap{position:relative;display:inline-flex;align-items:center;min-width:280px;flex:1}
.v35-search-wrap .search{padding-left:38px!important;width:100%}
.v35-search-icon{position:absolute;left:13px;top:50%;transform:translateY(-50%);pointer-events:none;color:#64748b;font-size:16px;z-index:1}


/* V36 targeted fixes only */
/* Payment: one visible percent sign only. */
.v30pctLabel{display:none!important}
#sqrFormHost .deposit-percent>b{display:none!important}
/* Revision search: same compact width as SQR search. */
#revision .v35-search-wrap{position:relative!important;display:inline-block!important;width:340px!important;min-width:340px!important;max-width:340px!important;flex:0 0 340px!important}
#revision .v35-search-wrap .search{width:100%!important;min-width:0!important;max-width:none!important;padding-left:38px!important}
/* Warranty year field: inline, short, with requested hint. */
#sqrFormHost .optionrow:has(input.smallnum),#quotationFormHost .optionrow:has(input.smallnum){align-items:center!important}
#sqrFormHost .optionrow .inlinefield,#quotationFormHost .optionrow .inlinefield{display:inline-flex!important;align-items:center!important;gap:6px!important;margin-left:4px!important}
#sqrFormHost .smallnum,#quotationFormHost .smallnum{width:72px!important;min-width:72px!important;max-width:72px!important}
/* Delivery custom items */
.v36-delivery-items{margin-top:10px;padding:10px 12px;border:1px solid #d7e6f6;border-radius:9px;background:#f8fbff}
.v36-delivery-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:7px 0}
.v36-delivery-row .v36-days{width:86px!important;min-width:86px!important;max-width:86px!important}
.v36-delivery-row .trash{margin-left:4px}
/* More popup: keep width, shrink only vertical blank space. */
.modal:has(.v31-more-menu) .box{height:auto!important;min-height:0!important;max-height:90vh!important}
.modal:has(.v31-more-menu) .v31-more-menu{margin-bottom:0!important;padding-bottom:0!important}
@media(max-width:950px){#revision .v35-search-wrap{width:180px!important;min-width:180px!important;max-width:180px!important;flex-basis:180px!important}}


/* V37: one standard UI across Admin/Sales, SQR/Quotation. */
.v37-warranty-first{display:flex!important;align-items:center!important;gap:6px!important;flex-wrap:nowrap!important}
.v37-warranty-first>label{display:inline-flex!important;align-items:center!important;gap:6px!important;white-space:nowrap!important;margin:0!important}
.v37-warranty-first .inlinefield{display:inline-flex!important;align-items:center!important;gap:6px!important;margin:0!important;white-space:nowrap!important}
.v37-warranty-first input[type="number"]{width:72px!important;min-width:72px!important;max-width:72px!important;margin:0!important}
.v37-delivery-items{margin-top:10px;padding:10px 12px;border:1px solid #d7e6f6;border-radius:9px;background:#f8fbff}
.v37-delivery-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:7px 0}
.v37-delivery-row .v37-item{width:240px!important;min-width:160px!important;max-width:320px!important}
.v37-delivery-row .v37-days{width:86px!important;min-width:86px!important;max-width:86px!important}
.v37-delivery-row .trash{margin-left:4px}
/* More popup: preserve width, fit height to content. */
.modal.v37-more-modal .box{height:auto!important;min-height:0!important;max-height:90vh!important;padding-bottom:16px!important}
.modal.v37-more-modal .body{height:auto!important;min-height:0!important;padding-bottom:0!important}
.modal.v37-more-modal .v31-more-menu{margin:0!important;padding:0!important}
/* Search in edit-request page = SQR compact search standard. */
#revision .v35-search-wrap{width:340px!important;min-width:340px!important;max-width:340px!important;flex:0 0 340px!important}
@media(max-width:950px){#revision .v35-search-wrap{width:180px!important;min-width:180px!important;max-width:180px!important;flex-basis:180px!important}}


/* V38 LOCKED PATCH: only the four user-approved changes. */
.modal.v38-more-modal .box{height:auto!important;min-height:0!important;max-height:90vh!important;padding-bottom:14px!important}
.modal.v38-more-modal .body{height:auto!important;min-height:0!important;padding-bottom:0!important}
.modal.v38-more-modal .v31-more-menu{margin-bottom:0!important;padding-bottom:0!important}
#revision.v38-sales-revision table tr>th:nth-child(5),#revision.v38-sales-revision table tr>td:nth-child(5){display:none!important}


/* ADMIN SQR CHECK 04 — header only, scoped to Admin SQR form */
#sqrFormHost.admin-sqr-check02 .sqr-request-tab{
  display:flex!important;align-items:center!important;justify-content:space-between!important;
  width:100%!important;box-sizing:border-box!important;
  background:linear-gradient(135deg,#dff1ff,#e9fbf5,#fff1f7)!important;
  border:1px solid #cfe5ee!important;border-radius:18px!important;
  padding:17px 20px!important;margin:0 0 14px 0!important;
  color:var(--text)!important;min-height:74px!important;
}
#sqrFormHost.admin-sqr-check02 .sqr-request-tab .admin-sqr-title-left{
  font-size:23px!important;font-weight:800!important;line-height:1.25!important;
}
#sqrFormHost.admin-sqr-check02 .sqr-request-tab .admin-sqr-user-right{
  margin-left:auto!important;text-align:right!important;font-size:14px!important;font-weight:700!important;line-height:1.35!important;
}
#sqrFormHost.admin-sqr-check02 .sqr-request-tab .admin-sqr-user-right small{display:block!important;font-size:12px!important;font-weight:500!important;opacity:.72!important;margin-top:2px!important}

/* CHECK 05: hide the original duplicate Admin identity block only inside Admin SQR form header.
   The identity remains once inside the pastel .sqr-request-tab header. */
#sqrFormHost.admin-sqr-check02 header.top > div:not(.sqr-request-tab){display:none!important;}


/* CHECK 12 — Admin SQR only: consistent full-row widths and short 'ระบุ' inputs. */
#sqrFormHost.admin-sqr-check02 .section,
#sqrFormHost.admin-sqr-check02 .panel,
#sqrFormHost.admin-sqr-check02 .quick,
#sqrFormHost.admin-sqr-check02 .field,
#sqrFormHost.admin-sqr-check02 textarea{box-sizing:border-box!important;max-width:none!important;}
#sqrFormHost.admin-sqr-check02 .section,
#sqrFormHost.admin-sqr-check02 .panel,
#sqrFormHost.admin-sqr-check02 .quick{width:100%!important;}
#sqrFormHost.admin-sqr-check02 .panel>textarea,
#sqrFormHost.admin-sqr-check02 .field>textarea{width:100%!important;}
#sqrFormHost.admin-sqr-check02 .smallnum,
#sqrFormHost.admin-sqr-check02 .v37-warranty-first input[type="number"],
#sqrFormHost.admin-sqr-check02 .v37-delivery-row .v37-days{width:86px!important;min-width:86px!important;max-width:86px!important;height:40px!important;padding:9px 10px!important;}


#quotationFormHost .q20-panel{width:100%!important;display:block!important;box-sizing:border-box!important;padding:13px!important}
#quotationFormHost .q20-line{display:flex!important;align-items:center!important;gap:10px!important;flex-wrap:wrap!important;width:100%!important;margin:6px 0!important}
#quotationFormHost .q20-line label{display:inline-flex!important;align-items:center!important;gap:6px!important;white-space:nowrap!important;width:auto!important;min-width:0!important;margin:0!important}
#quotationFormHost .q20-line input[type=checkbox]{width:16px!important;height:16px!important;min-width:16px!important;max-width:16px!important;flex:0 0 16px!important;margin:0!important;padding:0!important}
#quotationFormHost .q20-short{width:86px!important;min-width:86px!important;max-width:86px!important;height:40px!important;flex:0 0 86px!important;margin:0!important}
#quotationFormHost .q20-deposit{box-sizing:border-box!important;width:min(820px,calc(100% - 28px))!important;max-width:820px!important;margin:6px 0 12px 28px!important;padding:12px 14px!important;border:1px solid #d7e6f6!important;border-radius:9px!important;background:#f8fbff!important}
#quotationFormHost .q20-hidden{display:none!important}
#quotationFormHost .q20-deposit-head{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:16px!important;width:100%!important;margin-bottom:8px!important}
#quotationFormHost .q20-inst{display:grid!important;grid-template-columns:78px 110px minmax(0,1fr) 38px!important;gap:8px!important;align-items:center!important;width:100%!important;margin:7px 0!important}
#quotationFormHost .q20-inst .q20-pct{width:86px!important;height:40px!important;margin:0!important}
#quotationFormHost .q20-inst .q20-note{width:100%!important;height:40px!important;margin:0!important}
#quotationFormHost .q20-delivery-items{width:100%!important;margin:8px 0!important}
#quotationFormHost .q20-item{display:flex!important;align-items:center!important;gap:8px!important;flex-wrap:wrap!important;width:100%!important;margin:7px 0!important}
#quotationFormHost .q20-item-name{width:240px!important;min-width:180px!important;max-width:240px!important;height:40px!important;flex:0 0 240px!important;margin:0!important}
#quotationFormHost .q20-full{display:block!important;width:100%!important;max-width:none!important;height:44px!important;margin:6px 0 10px!important}
#quotationFormHost .q20-label{display:block!important;font-weight:700!important;margin-top:10px!important}
#quotationFormHost .q20-warranty-line{display:flex!important;align-items:center!important;gap:8px!important;flex-wrap:nowrap!important;width:100%!important;min-height:42px!important;margin:4px 0!important}
#quotationFormHost .q20-warranty-line label{display:inline-flex!important;align-items:center!important;gap:7px!important;width:auto!important;min-width:0!important;white-space:nowrap!important;margin:0!important}
#quotationFormHost .q20-warranty-line input[type=checkbox]{width:16px!important;height:16px!important;min-width:16px!important;max-width:16px!important;flex:0 0 16px!important;margin:0!important}
#quotationFormHost .q20-other-detail{width:min(520px,70%)!important;height:40px!important;margin:0!important}
#quotationFormHost .q20-trash{width:34px!important;min-width:34px!important;height:34px!important;padding:0!important}
@media(max-width:700px){#quotationFormHost .q20-deposit{margin-left:0!important;width:100%!important}#quotationFormHost .q20-inst{grid-template-columns:72px 95px minmax(0,1fr) 34px!important}#quotationFormHost .q20-warranty-line{flex-wrap:wrap!important}}


/* CHECK 25: All Quotations only — compact More popup. No navigation hooks. */
.modal:has(.v31-more-menu) .box{width:min(380px,92vw)!important;height:auto!important;min-height:0!important;max-height:90vh!important}
.modal:has(.v31-more-menu) .body{height:auto!important;min-height:0!important}
.modal:has(.v31-more-menu) .v31-more-menu{min-width:0!important;width:100%!important;margin:0!important;padding:0!important}


#sqr #v31FilterBtn,
#sqr .v32-filter-btn,
#sqr .v33-filter-btn,
#sqr button[data-filter-btn],
#sqr .toolbar button:not([onclick*="openSQRForm"]):not(.check28-keep){display:none!important}


/* Sales SQR topmost content header: pastel across the whole bar. */
#sqrFormHost.sales-sqr-check32 > main.main > header.top{
  background:#dceff8!important;
  border:1px solid #cfe3ef!important;
  border-radius:12px!important;
  box-shadow:none!important;
}


/* Scoped ONLY to Sales SQR form. Match the locked Dashboard .title pastel. */
#sqrFormHost.sales-sqr-check32 > main.main > header.top{
  background:linear-gradient(135deg,#dff1ff,#e9fbf5,#fff1f7)!important;
  border:1px solid #cfe5ee!important;
  border-radius:18px!important;
}


/* Scope strictly to Sales SQR form. Do not alter Admin, Dashboard, or New Quotation. */
#sqrFormHost.check37-sales-sqr .delivery-block{
  display:block!important;
  width:100%!important;
}
#sqrFormHost.check37-sales-sqr .delivery-block > .delivery-main-row{
  display:flex!important;
  width:100%!important;
  flex:0 0 100%!important;
  align-items:center!important;
  flex-wrap:wrap!important;
}
#sqrFormHost.check37-sales-sqr .delivery-block > #deliveryOtherItems{
  clear:both!important;
  float:none!important;
  position:static!important;
  width:100%!important;
  max-width:none!important;
  flex:0 0 100%!important;
  box-sizing:border-box!important;
  margin:8px 0 12px 0!important;
}
#sqrFormHost.check37-sales-sqr .delivery-block > #deliveryOtherItems:not(.hidden){display:block!important}
#sqrFormHost.check37-sales-sqr .delivery-block > #deliveryOtherItems.hidden{display:none!important}
#sqrFormHost.check37-sales-sqr .delivery-block > #deliveryOtherItems #deliveryItemRows,
#sqrFormHost.check37-sales-sqr .delivery-block > #deliveryOtherItems .delivery-item-row{
  width:100%!important;
}


/* Sales SQR: exactly one pastel top bar, title left + logged-in Sales right. */
#sqrFormHost.check41-sales-sqr > main.main > header.top{
  display:flex!important;align-items:center!important;justify-content:space-between!important;gap:16px!important;
  width:100%!important;box-sizing:border-box!important;
  background:linear-gradient(135deg,#dff1ff 0%,#e9fbf5 52%,#fff1f7 100%)!important;
  border:1px solid #cfe5ee!important;border-radius:18px!important;padding:13px 26px!important;min-height:68px!important;
}
#sqrFormHost.check41-sales-sqr > main.main > header.top > .sqr-request-tab{
  display:block!important;background:none!important;border:0!important;box-shadow:none!important;border-radius:0!important;
  margin:0!important;padding:0!important;color:#174a87!important;font-weight:800!important;
}
#sqrFormHost.check41-sales-sqr .check41-login-name{margin-left:auto!important;font-size:15px!important;font-weight:700!important;color:#174a87!important;white-space:nowrap!important}
/* Sales revision: no Sales name/column on the right; keep DOM for existing own-record logic. */
#revision.check41-sales-revision table th:nth-child(5),#revision.check41-sales-revision table td:nth-child(5){display:none!important}
/* Sales New Quotation Delivery: options end first; Item is a separate full row below. */
#quotationFormHost.check41-sales-newqa [data-q20="delivery"]{display:block!important;width:100%!important}
#quotationFormHost.check41-sales-newqa [data-q20="delivery"] > .q20-line:first-child{display:flex!important;width:100%!important;flex-wrap:wrap!important}
#quotationFormHost.check41-sales-newqa [data-q20="delivery"] > .q20-line:first-child + .q20-delivery-items{
  display:block!important;clear:both!important;width:100%!important;flex-basis:100%!important;margin:10px 0 12px!important;position:static!important;float:none!important;box-sizing:border-box!important
}
#quotationFormHost.check41-sales-newqa [data-q20="delivery"] > .q20-line:first-child + .q20-delivery-items.q20-hidden{display:none!important}
#quotationFormHost.check41-sales-newqa .q20-delivery-items > .q20-item{display:flex!important;align-items:center!important;gap:8px!important;flex-wrap:wrap!important;width:100%!important}
/* Report filters as compact list rows. */
.check41-report-filters{border:1px solid #dce6f2;border-radius:10px;overflow:hidden;background:#fff;margin-bottom:14px}
.check41-filter-row{display:grid;grid-template-columns:190px minmax(0,1fr);align-items:center;gap:12px;padding:11px 14px;border-bottom:1px solid #e8eef5}
.check41-filter-row:last-child{border-bottom:0}.check41-filter-row label{font-weight:700;color:#334155}.check41-filter-row input{width:100%;box-sizing:border-box;border:1px solid #cbd8e8;border-radius:7px;padding:9px 10px;background:#fff}.check41-pair{display:grid;grid-template-columns:1fr 1fr;gap:10px}
@media(max-width:700px){.check41-filter-row{grid-template-columns:1fr}.check41-pair{grid-template-columns:1fr}}


/* CHECK42: report popup controls only */
.check42-report-filters{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px 20px;margin:12px 0 18px}
.check42-report-filters .check42-field{display:flex;flex-direction:column;gap:7px;min-width:0}
.check42-report-filters label{font-weight:600;color:#365c71}
.check42-report-filters input{box-sizing:border-box;width:100%;height:42px;min-width:0;border:1px solid #b6d9e9;border-radius:9px;background:#eaf7ff;color:#26465c;padding:8px 12px;font:inherit}
.check42-report-filters input:focus{outline:2px solid #91cce8;outline-offset:1px}
.check42-money{display:flex;align-items:center;gap:10px}.check42-money input{flex:1}.check42-money span{white-space:nowrap;color:#365c71}
@media(max-width:600px){.check42-report-filters{grid-template-columns:1fr}}


#sqrFormHost.check46-sales-sqr .check46-item-line{display:block!important;width:100%!important;max-width:none!important;flex:0 0 100%!important;clear:both!important;float:none!important;position:static!important;margin:12px 0!important;box-sizing:border-box!important}
#sqrFormHost.check46-sales-sqr .check46-item-line[style*="display: none"]{display:none!important}

#cnr46-customers,#cnr46-products{margin-top:12px} #customerModal:not(.hidden){display:flex!important;position:fixed;inset:0;background:rgba(9,30,66,.45);z-index:9999;align-items:flex-start;justify-content:center;padding:24px;overflow:auto}#customerModal.hidden{display:none!important}#customerModal .modalbox{width:min(1180px,100%);background:#fff;border-radius:12px;box-shadow:0 18px 55px rgba(0,0,0,.25);overflow:hidden}#customerModal .modalhead{background:#1877f2;color:#fff;padding:15px 20px;display:flex;justify-content:space-between;align-items:center;font-size:19px;font-weight:800}#customerModal .modalbody{padding:18px}#customerModal .grid2{display:grid;grid-template-columns:1fr 1fr;gap:18px}#customerModal .field{margin:9px 0}#customerModal .field label{display:block;font-size:13px;font-weight:700;margin-bottom:5px}#customerModal input,#customerModal select,#customerModal textarea{font:inherit;width:100%;border:1px solid #cbd8e8;border-radius:7px;padding:9px 10px;background:#fff}#customerModal input[type=radio]{width:auto}#customerModal .checks{display:flex;gap:18px}#customerModal .section{background:#eaf4ff;border-left:4px solid #1877f2;padding:9px 12px;border-radius:6px;font-weight:800;margin:16px 0 10px}#customerModal .tablewrap{overflow:auto}#customerModal table{width:100%;border-collapse:collapse}#customerModal td,#customerModal th{padding:8px;border-bottom:1px solid #e8eef5}#customerModal .actions{display:flex;gap:8px;justify-content:flex-end;margin-top:12px}#customerModal .btn{border:0;border-radius:7px;padding:9px 13px;cursor:pointer}#customerModal .primary{background:#1877f2;color:white}#customerModal .secondary{background:#eaf2fb}#customerModal .green{background:#159447;color:#fff}#customerModal .x{border:0;background:transparent;color:white;font-size:24px;cursor:pointer}@media(max-width:900px){#customerModal .grid2{grid-template-columns:1fr}} .cnr46-grid{overflow:auto} .cnr46-grid table{width:100%;border-collapse:collapse} .cnr46-grid th,.cnr46-grid td{padding:9px;border-bottom:1px solid #e8eef5;text-align:left} .cnr46-grid th{background:#eaf8fb} .cnr46-filter{margin:8px 0;display:flex;gap:8px;flex-wrap:wrap;align-items:center}.cnr46-filter input,.cnr46-filter select{padding:9px;border:1px solid #d8e7ee;border-radius:9px;background:white}.cnr46-hint{font-size:12px;color:#6d8493;margin:8px 0}.cnr46-live{font-size:12px;color:#22617d}.cnr46-empty{padding:13px;color:#6d8493}

#quotationFormHost [data-q20="warranty"] [data-wother],
#quotationFormHost .v32-warranty-other input[type="checkbox"],
#sqrFormHost .v32-warranty-other input[type="checkbox"]{
  appearance:auto!important;-webkit-appearance:checkbox!important;
  pointer-events:auto!important;visibility:visible!important;opacity:1!important;
  width:16px!important;height:16px!important;min-width:16px!important;
  cursor:pointer!important;position:relative!important;z-index:2!important;
}
#quotationFormHost [data-q20="warranty"] label:has([data-wother]),
#quotationFormHost .v32-warranty-other label,#sqrFormHost .v32-warranty-other label{cursor:pointer!important;pointer-events:auto!important}

#quotationFormHost .cnr53-other,#sqrFormHost .cnr53-other{display:flex!important;align-items:center;gap:12px;flex-wrap:wrap;margin:9px 0}#quotationFormHost .cnr53-other label,#sqrFormHost .cnr53-other label{display:inline-flex!important;align-items:center;gap:7px;cursor:pointer;pointer-events:auto!important}#quotationFormHost .cnr53-other input[type=checkbox],#sqrFormHost .cnr53-other input[type=checkbox]{appearance:auto!important;opacity:1!important;visibility:visible!important;pointer-events:auto!important;width:16px!important;height:16px!important;position:static!important}#quotationFormHost .cnr53-other .cnr53-detail,#sqrFormHost .cnr53-other .cnr53-detail{min-width:180px;max-width:420px;padding:8px;border:1px solid #cbd5e1;border-radius:6px}#quotationFormHost .cnr53-other .cnr53-detail[hidden],#sqrFormHost .cnr53-other .cnr53-detail[hidden]{display:none!important}

#customers #cnr46-customers .cnr46-filter-toggle{display:none!important}
#customers #cnr46-customers .cnr46-filter-select{display:none}


/* Customer page only: remove duplicate lower search/refresh/status area, retain data table. */
#customers #cnr46-customers > .cnr46-filter,
#customers #cnr46-customers > .cnr46-hint{display:none!important}
#customers .toolbar .cnr74-filter-select{display:none!important;min-width:130px;padding:8px;border:1px solid #cbd8e8;border-radius:8px;background:white}
#customers .toolbar .cnr74-filter-select.cnr74-open{display:inline-block!important}


#customers table.table th{vertical-align:top}
#customers table.table th .cnr-v77-head-title{display:block;font-weight:800}
#customers table.table th .cnr-v77-head-filter{display:none!important;width:100%;box-sizing:border-box;min-height:34px;margin-top:6px;padding:5px 7px;border:1px solid #cbd8e8;border-radius:7px;background:#fff;font:inherit}
#customers table.table.cnr-v77-filter-open th .cnr-v77-head-filter{display:block!important}
#customers .toolbar #cnr-v77-filter-btn{white-space:nowrap}


#products .cnr-v81-product-filter-btn{white-space:nowrap}
#products .cnr-v81-head-filter{display:none;width:100%;box-sizing:border-box;margin-top:6px;padding:7px 8px;border:1px solid #cbd8e8;border-radius:7px;background:#fff;font:inherit;min-width:110px}
#products table.cnr-v81-filter-open .cnr-v81-head-filter{display:block}
#products table.cnr-v81-filter-open th{vertical-align:top}
#products table.cnr-v81-product-table th:nth-child(1){width:16%}
#products table.cnr-v81-product-table th:nth-child(2){width:40%}


#revision .v104-revision-searchbar{margin-bottom:12px;display:flex!important;justify-content:flex-end!important;align-items:center!important}
#revision .v104-revision-searchbar .search{width:100%;max-width:520px;box-sizing:border-box}
#revision .v104-status-cell{white-space:nowrap}
#revision .v104-status-select{min-width:145px;padding:7px 10px;border:1px solid #d8e7ee;border-radius:8px;background:#fff;color:#334155;font:inherit}
#revision .v104-status-head{white-space:nowrap}


/* V105: remove the visible status column from Sales > ขอแก้ไขใบเสนอราคา. */
body:not(.sales-mode) #revision .v104-status-head,
body:not(.sales-mode) #revision .v104-status-cell{display:none!important;}


/* V113 FINAL: only the existing Sales Revision search field. Keep one search control and place it at the far right. */
#revision .v104-revision-searchbar{
  display:flex!important;
  flex-direction:row!important;
  justify-content:flex-end!important;
  align-items:center!important;
  width:100%!important;
  margin-left:0!important;
  margin-right:0!important;
}
#revision .v104-revision-searchbar #v104RevisionSearch{
  display:block!important;
  width:340px!important;
  min-width:340px!important;
  max-width:340px!important;
  flex:0 0 340px!important;
  margin-left:auto!important;
  margin-right:0!important;
  box-sizing:border-box!important;
}


#quotationFormHost.v115-sales-delivery-no-items #deliveryOtherItems,
#quotationFormHost.v115-sales-delivery-no-items .v36-delivery-items,
#quotationFormHost.v115-sales-delivery-no-items .v37-delivery-items,
#quotationFormHost.v115-sales-delivery-no-items .check14-delivery-items,
#quotationFormHost.v115-sales-delivery-no-items .q20-delivery-items {display:none!important}
/* V124 Sales New Quotation Warranty: apply to the actual runtime panel, not
   only static markup. Scoped to the existing Sales-only role class.
   Admin Warranty (V93) and all other locked screens are not targeted. */
#quotationFormHost.v115-sales-delivery-no-items #quotationWarrantyExact > .optionrow,
#quotationFormHost.v115-sales-delivery-no-items [data-q20="warranty"] > .q20-warranty-line {
  display:flex!important;
  flex-direction:row!important;
  flex-wrap:wrap!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:8px!important;
  text-align:left!important;
}
#quotationFormHost.v115-sales-delivery-no-items #quotationWarrantyExact > .optionrow > label,
#quotationFormHost.v115-sales-delivery-no-items #quotationWarrantyExact > label,
#quotationFormHost.v115-sales-delivery-no-items [data-q20="warranty"] > .q20-warranty-line > label {
  display:inline-flex!important;
  flex-direction:row!important;
  align-items:center!important;
  justify-content:flex-start!important;
  flex:0 1 auto!important;
  width:max-content!important;
  max-width:100%!important;
  min-width:0!important;
  float:none!important;
  text-align:left!important;
  gap:8px!important;
  padding:0!important;
  margin:0!important;
}
#quotationFormHost.v115-sales-delivery-no-items #quotationWarrantyExact > .optionrow > label > input[type="checkbox"],
#quotationFormHost.v115-sales-delivery-no-items #quotationWarrantyExact > label > input[type="checkbox"],
#quotationFormHost.v115-sales-delivery-no-items [data-q20="warranty"] > .q20-warranty-line > label > input[type="checkbox"] {
  display:inline-block!important;
  position:static!important;
  inset:auto!important;
  float:none!important;
  transform:none!important;
  order:-1!important;
  flex:0 0 17px!important;
  width:17px!important;
  min-width:17px!important;
  max-width:17px!important;
  height:17px!important;
  margin:0!important;
  opacity:1!important;
  visibility:visible!important;
  pointer-events:auto!important;
  appearance:auto!important;
  -webkit-appearance:checkbox!important;
}


/* V121: Match the existing SQR .status badge styling within Sales Revision only.
   Preserve the native select and its existing change/storage handlers. */
#revision.v118-sales-status .v104-status-cell .v104-status-select {
  -webkit-appearance: none !important;
  appearance: none !important;
  background: #e4f7ef !important;
  background-image: none !important;
  color: #237b65 !important;
  border: 0 !important;
  border-radius: 999px !important;
  padding: 5px 8px !important;
  margin: 0 !important;
  min-width: 0 !important;
  min-height: 0 !important;
  width: auto !important;
  max-width: 100% !important;
  height: auto !important;
  font-size: 11px !important;
  line-height: normal !important;
  font-weight: 400 !important;
  box-shadow: none !important;
  cursor: pointer;
}
#revision.v118-sales-status .v104-status-cell .v104-status-select:focus-visible {
  outline: 2px solid #74B98D;
  outline-offset: 2px;
}


body #revision.v118-sales-status table .v104-status-head,
body #revision.v118-sales-status table .v104-status-cell {display:table-cell!important;visibility:visible!important;}
#revision.v118-sales-status table .v104-status-head {white-space:nowrap;}


/* ADMIN SQR CHECK 02 — scoped only to Admin SQR form */
#sqrFormHost.admin-sqr-check02 .sqr-request-tab{
  display:inline-flex!important;align-items:center!important;min-height:40px!important;
  padding:9px 14px!important;border-radius:9px!important;
  background:#dceff8!important;color:#174a87!important;font-weight:800!important;
  border:1px solid #cfe3ef!important;
}
#sqrFormHost.admin-sqr-check02 .v37-warranty-first{
  display:flex!important;align-items:center!important;column-gap:6px!important;
  min-height:34px!important;margin:0!important;padding:0!important;
}
#sqrFormHost.admin-sqr-check02 .v37-warranty-first>label{
  display:inline-flex!important;align-items:center!important;gap:6px!important;
  margin:0!important;padding:0!important;line-height:34px!important;
}
#sqrFormHost.admin-sqr-check02 .v37-warranty-first .inlinefield{
  display:inline-flex!important;align-items:center!important;gap:6px!important;
  margin:0!important;padding:0!important;line-height:34px!important;
}
#sqrFormHost.admin-sqr-check02 .v37-delivery-items{
  display:block;clear:both;width:100%;margin:8px 0 12px 0!important;
}


/* ADMIN SQR CHECK 03 — ONLY Admin SQR form. Align shared option-row spacing. */
#sqrFormHost.admin-sqr-check02 .sqr-request-tab{
  display:block!important;width:100%!important;
  font-size:23px!important;font-weight:800!important;
  background:linear-gradient(135deg,#dff1ff,#e9fbf5,#fff1f7)!important;
  border:1px solid #cfe5ee!important;border-radius:18px!important;
  padding:17px 20px!important;margin:0 0 14px 0!important;
  color:var(--text)!important;min-height:0!important;
}
/* Payment / Delivery: same rhythm between checkbox, label, input and unit. */
#sqrFormHost.admin-sqr-check02 .payment-main,
#sqrFormHost.admin-sqr-check02 .delivery-main-row{
  display:flex!important;align-items:center!important;gap:16px!important;flex-wrap:wrap!important;
}
#sqrFormHost.admin-sqr-check02 .payment-main>label,
#sqrFormHost.admin-sqr-check02 .delivery-main-row>label{
  display:inline-flex!important;align-items:center!important;gap:6px!important;margin:0!important;
}
#sqrFormHost.admin-sqr-check02 .payment-main>.inlinefield{
  display:inline-flex!important;align-items:center!important;gap:6px!important;margin-left:-10px!important;
}
#sqrFormHost.admin-sqr-check02 .delivery-days-label{
  display:inline-flex!important;align-items:center!important;gap:6px!important;
}
/* Warranty: first line uses the same checkbox/text spacing as the other warranty rows. */
#sqrFormHost.admin-sqr-check02 .v37-warranty-first{
  display:flex!important;align-items:center!important;gap:6px!important;
  min-height:34px!important;margin:0!important;padding:0!important;
}
#sqrFormHost.admin-sqr-check02 .v37-warranty-first>label,
#sqrFormHost.admin-sqr-check02 .v37-warranty-first>.inlinefield{
  display:inline-flex!important;align-items:center!important;gap:6px!important;margin:0!important;padding:0!important;
}


/* CHECK 06 — Admin SQR only: one spacing rhythm for every checkbox/text row. */
#sqrFormHost.admin-sqr-check02{
  --sqr-cb-text-gap:10px;
  --sqr-control-gap:10px;
  --sqr-row-gap:12px;
}
#sqrFormHost.admin-sqr-check02 input[type="checkbox"],
#sqrFormHost.admin-sqr-check02 input[type="radio"]{
  margin:0!important;
  flex:0 0 auto!important;
}
#sqrFormHost.admin-sqr-check02 .termrow,
#sqrFormHost.admin-sqr-check02 .optionrow{
  align-items:center!important;
  column-gap:var(--sqr-row-gap)!important;
}
#sqrFormHost.admin-sqr-check02 .termrow label,
#sqrFormHost.admin-sqr-check02 .optionrow label,
#sqrFormHost.admin-sqr-check02 .optionlist>label,
#sqrFormHost.admin-sqr-check02 .send-options .optionrow label,
#sqrFormHost.admin-sqr-check02 .checks label{
  display:inline-flex!important;
  align-items:center!important;
  gap:var(--sqr-cb-text-gap)!important;
  margin:0!important;
  padding:0!important;
}
/* Inputs/units that continue after a label use the same gap everywhere. */
#sqrFormHost.admin-sqr-check02 .inlinefield,
#sqrFormHost.admin-sqr-check02 .payment-main>.inlinefield{
  display:inline-flex!important;
  align-items:center!important;
  gap:var(--sqr-control-gap)!important;
  margin-left:0!important;
  padding:0!important;
}
#sqrFormHost.admin-sqr-check02 .payment-main,
#sqrFormHost.admin-sqr-check02 .delivery-main-row{
  display:flex!important;
  align-items:center!important;
  gap:18px!important;
  flex-wrap:wrap!important;
}
#sqrFormHost.admin-sqr-check02 .delivery-main-row>label,
#sqrFormHost.admin-sqr-check02 .payment-main>label,
#sqrFormHost.admin-sqr-check02 .delivery-days-label{
  gap:var(--sqr-cb-text-gap)!important;
}
/* Within composite labels: text -> numeric input -> unit has a consistent visual gap. */
#sqrFormHost.admin-sqr-check02 .delivery-days-label input.smallnum{
  margin-left:var(--sqr-control-gap)!important;
  margin-right:0!important;
}
#sqrFormHost.admin-sqr-check02 .delivery-days-label span{
  margin-left:0!important;
}
#sqrFormHost.admin-sqr-check02 .v37-warranty-first{
  display:flex!important;
  align-items:center!important;
  gap:var(--sqr-control-gap)!important;
  margin:9px 0!important;
  padding:0!important;
}
#sqrFormHost.admin-sqr-check02 .v37-warranty-first>label{
  gap:var(--sqr-cb-text-gap)!important;
}
#sqrFormHost.admin-sqr-check02 .v37-warranty-first>.inlinefield{
  gap:var(--sqr-control-gap)!important;
}


/* CHECK 07 — Admin SQR form header only. One full pastel header, one Admin identity. */
#sqrFormHost.admin-sqr-check02 > main.main > header.top{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  width:100%!important;
  min-height:78px!important;
  padding:0!important;
  margin:0 0 14px 0!important;
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  gap:0!important;
}
#sqrFormHost.admin-sqr-check02 > main.main > header.top > .sqr-request-tab{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  width:100%!important;
  min-height:78px!important;
  box-sizing:border-box!important;
  padding:16px 22px!important;
  margin:0!important;
  border-radius:18px!important;
  border:1px solid #cfe5ee!important;
  background:linear-gradient(135deg,#dff1ff,#e9fbf5,#fff1f7)!important;
  color:var(--text)!important;
}
#sqrFormHost.admin-sqr-check02 > main.main > header.top > div:nth-child(2){
  display:none!important;
}
#sqrFormHost.admin-sqr-check02 .sqr-request-tab .admin-sqr-title-left{
  display:block!important;
  font-size:23px!important;
  font-weight:800!important;
  line-height:1.25!important;
  margin:0!important;
}
#sqrFormHost.admin-sqr-check02 .sqr-request-tab .admin-sqr-user-right{
  display:block!important;
  margin-left:auto!important;
  text-align:right!important;
  font-size:14px!important;
  font-weight:700!important;
  line-height:1.25!important;
}
#sqrFormHost.admin-sqr-check02 .sqr-request-tab .admin-sqr-user-right small{
  display:block!important;
  margin-top:3px!important;
  font-size:12px!important;
  font-weight:500!important;
  opacity:.72!important;
}


/* CHECK 10 — Admin > ขอแก้ไขใบเสนอราคา: move search icon to the right only. */
body:not(.sales-mode) #revision .v35-search-wrap .search{
  padding-left:12px!important;
  padding-right:38px!important;
}
body:not(.sales-mode) #revision .v35-search-icon{
  left:auto!important;
  right:13px!important;
}


/* SQR: no Add Item button; keep the automatically-created Delivery item row. */
#sqrFormHost .v37-delivery-items .v37-add,
#sqrFormHost .v36-delivery-items .v36-add-delivery,
#sqrFormHost #deliveryOtherItems > button.delivery-add,
#sqrFormHost #deliveryOtherItems > #addDeliveryItem {display:none!important}


#quotationFormHost [data-q20="delivery"] .q20-line:last-child ~ .q20-item,
#quotationFormHost [data-q20="delivery"] .q20-line:last-child ~ .q20-delivery-items,
#quotationFormHost [data-q20="delivery"] .q20-line:last-child ~ button {display:none!important}


#revision .v33-rev-filter,#revision .v34-filter-row{display:none!important}
#revision .toolbar{display:flex!important;align-items:center!important;gap:8px!important;justify-content:flex-end!important}
#revision .v35-search-wrap{display:inline-flex!important;position:static!important;width:340px!important;min-width:340px!important;max-width:340px!important;flex:0 0 340px!important}
#revision .v35-search-wrap .search,#revision .toolbar>.search{width:340px!important;min-width:340px!important;max-width:340px!important;padding:10px 12px!important}
#revision .v35-search-icon{display:none!important}
#revision .check26-search-btn{display:inline-flex!important;align-items:center!important;justify-content:center!important;min-width:44px;height:40px;padding:0 12px;font-size:17px}
@media(max-width:950px){#revision .v35-search-wrap,#revision .v35-search-wrap .search,#revision .toolbar>.search{width:180px!important;min-width:180px!important;max-width:180px!important;flex-basis:180px!important}}


/* Scope strictly to New Quotation Delivery generated by q20. Mirror PASSED SQR v37 item block. */
#quotationFormHost [data-q20="delivery"] .q20-delivery-items{
  display:block;
  clear:both;
  width:100%!important;
  margin:10px 0 12px 0!important;
  padding:10px 12px!important;
  border:1px solid #d7e6f6!important;
  border-radius:9px!important;
  background:#f8fbff!important;
  box-sizing:border-box!important;
}
#quotationFormHost [data-q20="delivery"] .q20-delivery-items.q20-hidden{display:none!important}
#quotationFormHost [data-q20="delivery"] .q20-item{
  display:flex!important;
  align-items:center!important;
  gap:8px!important;
  flex-wrap:wrap!important;
  margin:7px 0!important;
  width:100%!important;
}
#quotationFormHost [data-q20="delivery"] .q20-item-name{
  width:240px!important;
  min-width:160px!important;
  max-width:320px!important;
  height:40px!important;
  margin:0!important;
  padding:9px 10px!important;
  box-sizing:border-box!important;
}
#quotationFormHost [data-q20="delivery"] .q20-item .q20-short{
  width:86px!important;
  min-width:86px!important;
  max-width:86px!important;
  height:40px!important;
  margin:0!important;
  padding:9px 10px!important;
  box-sizing:border-box!important;
}
#quotationFormHost [data-q20="delivery"] .q20-item .q20-trash{margin-left:4px!important}


#sqrFormHost.sales-sqr-check30 > main.main > header.top{
  min-height:68px!important;height:auto!important;background:#eaf4ff!important;
  border:1px solid #dce6f2!important;border-radius:12px!important;
  padding:12px 18px!important;margin:0 0 12px!important;
  display:flex!important;align-items:center!important;justify-content:space-between!important;gap:18px!important;
}
#sqrFormHost.sales-sqr-check30 > main.main > header.top > .sqr-request-tab{
  display:flex!important;flex:1 1 auto!important;align-items:center!important;
  min-height:42px!important;padding:0!important;margin:0!important;border:0!important;
  background:transparent!important;color:#174a87!important;font-weight:800!important;font-size:18px!important;
}
#sqrFormHost.sales-sqr-check30 > main.main > header.top > .check30-sales-user{
  display:block!important;text-align:right!important;color:#183153!important;font-weight:800!important;white-space:nowrap!important;
}
#sqrFormHost.sales-sqr-check30 > main.main > header.top > .check30-sales-user small{
  display:block!important;margin-top:2px!important;font-size:12px!important;font-weight:500!important;color:#71849c!important;
}
#sqrFormHost.sales-sqr-check30 .delivery-main-row{display:flex!important;align-items:center!important;gap:18px!important;flex-wrap:wrap!important}
#sqrFormHost.sales-sqr-check30 #deliveryOtherItems{display:block;margin:8px 0 12px 26px;padding:10px 12px;border:1px dashed #cbd9ea;border-radius:10px;background:#fbfdff}
#sqrFormHost.sales-sqr-check30 #deliveryOtherItems.hidden{display:none!important}
#sqrFormHost.sales-sqr-check30 #deliveryItemRows .delivery-item-row{display:flex!important;align-items:center!important;gap:10px!important;flex-wrap:wrap!important;margin:7px 0!important}
#sqrFormHost.sales-sqr-check30 #deliveryItemRows .item-no{width:78px!important;height:40px!important}
#sqrFormHost.sales-sqr-check30 #deliveryItemRows .wait-days{width:92px!important;height:40px!important}
#sqrFormHost.sales-sqr-check30 #deliveryOtherItems > .delivery-add{display:none!important}


/* Sales SQR only. Keep Admin and Sales Dashboard untouched. */
#sqrFormHost.sales-sqr-check31 > main.main > header.top{
  background:#dceff8!important;
  border-color:#cfe3ef!important;
}
#sqrFormHost.sales-sqr-check31 .section{
  background:#dceff8!important;
  color:#174a87!important;
  border:1px solid #cfe3ef!important;
  border-radius:9px!important;
  padding:9px 14px!important;
  font-weight:800!important;
}
/* The Delivery Item block is a full new row directly under the delivery choices. */
#sqrFormHost.sales-sqr-check31 .delivery-block > #deliveryOtherItems{
  display:block!important;
  clear:both!important;
  width:100%!important;
  margin:8px 0 12px 0!important;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
}
#sqrFormHost.sales-sqr-check31 .delivery-block > #deliveryOtherItems.hidden{display:none!important}
#sqrFormHost.sales-sqr-check31 .delivery-block > #deliveryOtherItems #deliveryItemRows{
  display:block!important;width:100%!important;
}
#sqrFormHost.sales-sqr-check31 .delivery-block > #deliveryOtherItems .delivery-item-row{
  display:flex!important;align-items:center!important;gap:10px!important;
  width:100%!important;margin:7px 0!important;flex-wrap:wrap!important;
}


body:has(#rs.active) #sqrform #sqrFormHost > main.main > header.top,
#sqrFormHost.check35-sales-active > main.main > header.top{
  background:linear-gradient(135deg,#dff1ff 0%,#e9fbf5 52%,#fff1f7 100%)!important;
  border:1px solid #cfe5ee!important;
  border-radius:18px!important;
  box-shadow:none!important;
}


#sqrFormHost.check36-sales-sqr .delivery-block > #deliveryOtherItems{
  display:block;clear:both;width:100%;margin:8px 0 12px 0!important;
}
#sqrFormHost.check36-sales-sqr .delivery-block > #deliveryOtherItems.hidden{display:none!important}
#sqrFormHost.check36-sales-sqr #deliveryItemRows .delivery-item-row{
  display:flex!important;align-items:center!important;gap:10px!important;width:100%!important;
}


#sqrFormHost.check38-sales-sqr .delivery-block > .v37-delivery-items{
  display:block;clear:both;width:100%;box-sizing:border-box;margin:10px 0 12px 0!important;
}
#sqrFormHost.check38-sales-sqr .delivery-block > .v37-delivery-items[style*="display: none"]{display:none!important}
#sqrFormHost.check38-sales-sqr .delivery-block > .v37-delivery-items .v37-delivery-row{
  display:flex!important;align-items:center!important;gap:8px!important;width:100%!important;flex-wrap:wrap!important;
}


#sqrFormHost.check39-sales-sqr .delivery-block{display:block!important;width:100%!important}
#sqrFormHost.check39-sales-sqr .delivery-block > .delivery-main-row{display:flex!important;width:100%!important;flex-wrap:wrap!important;align-items:center!important}
#sqrFormHost.check39-sales-sqr .delivery-block > .delivery-main-row + .v37-delivery-items{
  display:block;clear:both!important;float:none!important;position:static!important;width:100%!important;max-width:none!important;
  flex:none!important;box-sizing:border-box!important;margin:10px 0 12px 0!important
}
#sqrFormHost.check39-sales-sqr .delivery-block > .delivery-main-row + .v37-delivery-items[style*="display: none"]{display:none!important}
#sqrFormHost.check39-sales-sqr .v37-delivery-row{display:flex!important;align-items:center!important;gap:8px!important;flex-wrap:wrap!important;width:100%!important}


/* Sales SQR top bar: one clean pastel bar, no boxed mini-tab. */
#sqrFormHost.check40-sales .top{
  background:linear-gradient(135deg,#dff1ff,#e9fbf5,#fff1f7)!important;
  border:1px solid #cfe5ee!important;border-radius:18px!important;
  min-height:68px!important;height:auto!important;padding:13px 26px!important;
}
#sqrFormHost.check40-sales .top .sqr-request-tab{
  background:transparent!important;border:0!important;border-radius:0!important;
  padding:0!important;min-height:0!important;color:#174a87!important;font-weight:800!important;
}
#sqrFormHost.check40-sales .check40-login-name{font-size:15px;font-weight:700;color:#174a87;white-space:nowrap}
/* Sales New Quotation Delivery: Item container is a true full row after options. */
#quotationFormHost.check40-sales-newqa [data-q20="delivery"]{display:block!important;width:100%!important}
#quotationFormHost.check40-sales-newqa [data-q20="delivery"]>.q20-line:first-child{display:flex!important;width:100%!important;flex:0 0 100%!important}
#quotationFormHost.check40-sales-newqa [data-q20="delivery"]>.q20-line:first-child + .q20-delivery-items{
  display:block;clear:both!important;float:none!important;position:static!important;width:100%!important;max-width:none!important;
  flex:0 0 100%!important;margin:10px 0 12px 0!important;box-sizing:border-box!important
}
#quotationFormHost.check40-sales-newqa [data-q20="delivery"]>.q20-line:first-child + .q20-delivery-items.q20-hidden{display:none!important}
/* My Report: list-style filter rows instead of large grid boxes. */
.check40-report-filters{border:1px solid #dce6f2;border-radius:10px;overflow:hidden;background:#fff;margin-bottom:14px}
.check40-filter-row{display:grid;grid-template-columns:190px minmax(0,1fr);align-items:center;gap:12px;padding:11px 14px;border-bottom:1px solid #e8eef5}
.check40-filter-row:last-child{border-bottom:0}.check40-filter-row label{font-weight:700;color:#334155}
.check40-filter-row input{width:100%;box-sizing:border-box;border:1px solid #cbd8e8;border-radius:7px;padding:9px 10px;background:#fff}
.check40-value-pair{display:grid;grid-template-columns:1fr 1fr;gap:10px}
@media(max-width:700px){.check40-filter-row{grid-template-columns:1fr}.check40-value-pair{grid-template-columns:1fr}}


/* Report popup only: apply to actual inputs, not merely their surrounding panel. */
.check43-report-filters{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:14px 20px!important;margin:12px 0 18px!important}
.check43-report-filters .check43-field{display:flex!important;flex-direction:column!important;gap:7px!important;min-width:0!important}
.check43-report-filters .check43-field>label{font-weight:600!important;color:#365c71!important}
.check43-report-filters input#myReportCustomer,.check43-report-filters input#myReportMin,.check43-report-filters input#myReportFrom,.check43-report-filters input#myReportTo{display:block!important;box-sizing:border-box!important;width:100%!important;min-width:0!important;height:42px!important;border:1px solid #b6d9e9!important;border-radius:9px!important;background:#e3f4ff!important;background-color:#e3f4ff!important;color:#26465c!important;padding:8px 12px!important;font:inherit!important;box-shadow:none!important}
.check43-report-filters input:focus{outline:2px solid #91cce8!important;outline-offset:1px!important}
.check43-report-filters .check43-money{display:flex!important;align-items:center!important;gap:10px!important;min-width:0!important}
.check43-report-filters .check43-money input{flex:1 1 auto!important}.check43-report-filters .check43-money span{white-space:nowrap!important;color:#365c71!important}
@media(max-width:600px){.check43-report-filters{grid-template-columns:1fr!important}}


#quotationFormHost .q20-warranty-line,
#quotationFormHost .optionlist .optionrow,
#sqrFormHost .optionlist .optionrow,
#sqrFormHost .v37-warranty-first,
#quotationFormHost .cnr53-other,
#sqrFormHost .cnr53-other {
  display:flex!important; align-items:center!important; justify-content:flex-start!important;
  flex-wrap:wrap!important; gap:8px!important; width:100%!important;
  margin:5px 0!important; padding:0!important; min-height:32px!important;
}
#quotationFormHost .q20-warranty-line>label,
#quotationFormHost .optionlist .optionrow>label,
#sqrFormHost .optionlist .optionrow>label,
#sqrFormHost .v37-warranty-first>label,
#quotationFormHost .cnr53-other>label,
#sqrFormHost .cnr53-other>label {
  display:inline-flex!important; align-items:center!important; justify-content:flex-start!important;
  flex:0 1 auto!important; width:auto!important; min-width:0!important;
  margin:0!important; padding:0!important; gap:7px!important;
  white-space:normal!important; text-align:left!important; cursor:pointer;
}
#quotationFormHost .q20-warranty-line>label input[type="checkbox"],
#quotationFormHost .optionlist .optionrow>label input[type="checkbox"],
#sqrFormHost .optionlist .optionrow>label input[type="checkbox"],
#sqrFormHost .v37-warranty-first>label input[type="checkbox"],
#quotationFormHost .cnr53-other>label input[type="checkbox"],
#sqrFormHost .cnr53-other>label input[type="checkbox"] {
  position:static!important; display:inline-block!important; float:none!important;
  flex:0 0 16px!important; width:16px!important; min-width:16px!important;
  max-width:16px!important; height:16px!important; margin:0!important;
  opacity:1!important; visibility:visible!important; pointer-events:auto!important;
}
#quotationFormHost .cnr53-other .cnr53-detail,
#sqrFormHost .cnr53-other .cnr53-detail {flex:0 1 360px!important;min-width:150px!important;max-width:100%!important}


/* The existing form CSS stretches labels and pushes their checkboxes to the far edge.
   Anchor each checkbox to the start of its own label, without changing its DOM or event handlers. */
#quotationFormHost .q20-warranty-line > label,
#quotationFormHost .optionlist .optionrow > label,
#sqrFormHost .optionlist:not(.send-options) .optionrow > label,
#sqrFormHost .v37-warranty-first > label,
#quotationFormHost .cnr53-other > label,
#sqrFormHost .cnr53-other > label {
  position:relative!important;
  display:block!important;
  box-sizing:border-box!important;
  width:auto!important;
  max-width:100%!important;
  min-width:0!important;
  padding:0 0 0 26px!important;
  margin:0!important;
  text-align:left!important;
  line-height:24px!important;
}
#quotationFormHost .q20-warranty-line > label > input[type="checkbox"],
#quotationFormHost .optionlist .optionrow > label > input[type="checkbox"],
#sqrFormHost .optionlist:not(.send-options) .optionrow > label > input[type="checkbox"],
#sqrFormHost .v37-warranty-first > label > input[type="checkbox"],
#quotationFormHost .cnr53-other > label > input[type="checkbox"],
#sqrFormHost .cnr53-other > label > input[type="checkbox"] {
  position:absolute!important;
  left:0!important;
  top:4px!important;
  right:auto!important;
  bottom:auto!important;
  transform:none!important;
  float:none!important;
  display:block!important;
  width:16px!important;
  height:16px!important;
  margin:0!important;
  opacity:1!important;
  visibility:visible!important;
  pointer-events:auto!important;
  appearance:auto!important;
}


#products .toolbar .cnr-v78-product-filter{white-space:nowrap}
#products .toolbar .cnr-v78-product-filter-select{display:none!important;min-width:130px;padding:8px;border:1px solid #cbd8e8;border-radius:8px;background:#fff;font:inherit}
#products .toolbar .cnr-v78-product-filter-select.cnr-v78-open{display:inline-block!important}


#quotationFormHost .q20-warranty-line > label,
#quotationFormHost .optionlist .optionrow > label,
#sqrFormHost .optionlist:not(.send-options) .optionrow > label,
#sqrFormHost .v37-warranty-first > label,
#quotationFormHost .cnr53-other > label,
#sqrFormHost .cnr53-other > label {
  display:flex!important;
  flex-direction:row!important;
  justify-content:flex-end!important;
  align-items:center!important;
  width:auto!important;
  max-width:100%!important;
  padding:0!important;
  margin:0!important;
  gap:7px!important;
}
#quotationFormHost .q20-warranty-line > label > input[type="checkbox"],
#quotationFormHost .optionlist .optionrow > label > input[type="checkbox"],
#sqrFormHost .optionlist:not(.send-options) .optionrow > label > input[type="checkbox"],
#sqrFormHost .v37-warranty-first > label > input[type="checkbox"],
#quotationFormHost .cnr53-other > label > input[type="checkbox"],
#sqrFormHost .cnr53-other > label > input[type="checkbox"] {
  order:0!important;
  position:static!important;
  inset:auto!important;
  transform:none!important;
  float:none!important;
  flex:0 0 16px!important;
  width:16px!important;
  min-width:16px!important;
  max-width:16px!important;
  height:16px!important;
  margin:0!important;
  padding:0!important;
  opacity:1!important;
  visibility:visible!important;
  pointer-events:auto!important;
  appearance:auto!important;
}


/* V93: explicit final fix — quotation Warranty checkbox must be before its text. */
#quotationFormHost .panel.vertical-fields.checks .optionrow,
#quotationFormHost .panel.vertical-fields.checks .optionrow > label,
#quotationFormHost .panel.vertical-fields.checks > label {
  display:flex!important;
  flex-direction:row!important;
  align-items:center!important;
  justify-content:flex-start!important;
  text-align:left!important;
  width:100%!important;
  box-sizing:border-box!important;
}
#quotationFormHost .panel.vertical-fields.checks .optionrow > label {
  gap:8px!important;
  margin:0!important;
  padding:0!important;
  min-width:0!important;
  position:static!important;
}
#quotationFormHost .panel.vertical-fields.checks .optionrow > label > input[type="checkbox"],
#quotationFormHost .panel.vertical-fields.checks > label > input[type="checkbox"] {
  position:static!important;
  left:auto!important; right:auto!important; top:auto!important; bottom:auto!important;
  transform:none!important;
  float:none!important;
  order:-1!important;
  flex:0 0 17px!important;
  width:17px!important;
  min-width:17px!important;
  max-width:17px!important;
  height:17px!important;
  margin:0!important;
  padding:0!important;
  display:inline-block!important;
  opacity:1!important;
  visibility:visible!important;
  pointer-events:auto!important;
  appearance:auto!important;
  -webkit-appearance:checkbox!important;
}
#quotationFormHost .panel.vertical-fields.checks .optionrow > label .smallnum,
#quotationFormHost .panel.vertical-fields.checks .optionrow > label .mini {
  margin-left:0!important;
}
/* V128 Warranty-only correction: covers BOTH live layouts (#quotationWarrantyExact,
   and runtime [data-q20="warranty"] with either .q20-warranty-line or .optionrow).
   Does not touch SQR, Delivery, Remark, role handling, or any JavaScript. */
#quotationFormHost :is(#quotationWarrantyExact,[data-q20="warranty"]) :is(.optionrow,.q20-warranty-line,.cnr53-other) {
  display:flex!important;
  flex-direction:row!important;
  flex-wrap:wrap!important;
  justify-content:flex-start!important;
  align-items:center!important;
  text-align:left!important;
  width:100%!important;
}
#quotationFormHost :is(#quotationWarrantyExact,[data-q20="warranty"]) :is(.optionrow,.q20-warranty-line,.cnr53-other) > label,
#quotationFormHost #quotationWarrantyExact > label {
  display:inline-flex!important;
  flex-direction:row!important;
  flex-wrap:nowrap!important;
  align-items:center!important;
  justify-content:flex-start!important;
  text-align:left!important;
  width:max-content!important;
  max-width:100%!important;
  min-width:0!important;
  flex:0 1 auto!important;
  gap:8px!important;
  float:none!important;
  margin:0!important;
  padding:0!important;
}
#quotationFormHost :is(#quotationWarrantyExact,[data-q20="warranty"]) :is(.optionrow,.q20-warranty-line,.cnr53-other) > label > input[type="checkbox"],
#quotationFormHost #quotationWarrantyExact > label > input[type="checkbox"] {
  display:inline-block!important;
  order:-1!important;
  position:static!important;
  inset:auto!important;
  float:none!important;
  transform:none!important;
  flex:0 0 17px!important;
  width:17px!important;
  min-width:17px!important;
  max-width:17px!important;
  height:17px!important;
  margin:0!important;
  padding:0!important;
  opacity:1!important;
  visibility:visible!important;
  pointer-events:auto!important;
  appearance:auto!important;
  -webkit-appearance:checkbox!important;
}

/* V129: quotation Warranty / Remark uniform spacing only.
   Equal vertical rhythm, consistent checkbox/text gap, existing behavior retained.
   Scoped to quotation form; does not alter SQR, Delivery, or Dashboard. */
#quotationFormHost [data-q20="warranty"] > :is(.q20-warranty-line,.optionrow),
#quotationFormHost #quotationWarrantyExact > .optionrow {
  min-height:44px!important;
  margin:0!important;
  padding:2px 0!important;
  column-gap:10px!important;
  row-gap:4px!important;
  box-sizing:border-box!important;
  align-items:center!important;
}
#quotationFormHost :is(#quotationWarrantyExact,[data-q20="warranty"]) :is(.q20-warranty-line,.optionrow) > label {
  gap:10px!important;
  line-height:1.45!important;
  min-height:32px!important;
  margin:0!important;
  padding:0!important;
}
#quotationFormHost #quotationWarrantyExact {
  gap:0!important;
}
#quotationFormHost #quotationWarrantyExact > label {
  min-height:44px!important;
  box-sizing:border-box!important;
  line-height:1.45!important;
}
#quotationFormHost .remark-vertical .checks {
  display:flex!important;
  flex-direction:column!important;
  align-items:stretch!important;
  gap:0!important;
}
#quotationFormHost .remark-vertical .checks > label {
  display:flex!important;
  flex-direction:row!important;
  align-items:center!important;
  justify-content:flex-start!important;
  width:100%!important;
  min-height:44px!important;
  box-sizing:border-box!important;
  gap:10px!important;
  margin:0!important;
  padding:2px 0!important;
  line-height:1.45!important;
  text-align:left!important;
}
#quotationFormHost .remark-vertical .checks > label > input[type="checkbox"] {
  position:static!important;
  flex:0 0 17px!important;
  width:17px!important;
  min-width:17px!important;
  max-width:17px!important;
  height:17px!important;
  margin:0!important;
  padding:0!important;
  float:none!important;
  transform:none!important;
  order:-1!important;
}


#revision .toolbar:not(.v104-revision-searchbar){display:none!important}
#revision .v104-revision-searchbar{display:flex!important;justify-content:flex-end!important;align-items:center!important}


#quotationFormHost [data-q20="delivery"] [data-items] .b74-add-delivery-item{
  margin:8px 0 2px!important;display:inline-flex!important;align-items:center!important;
  justify-content:center!important;min-height:36px!important;cursor:pointer!important;
}


/* Scope is intentionally restricted to quotation-list action buttons and their popup. */
#allqa #qat td.actions.b77-actions{display:table-cell!important;white-space:nowrap!important;text-align:right!important;vertical-align:middle!important}
#allqa #qat .b77-actions-wrap{display:inline-flex;gap:7px;align-items:center;justify-content:flex-end;white-space:nowrap}
#allqa #qat .b77-action-btn{display:inline-flex;gap:7px;align-items:center;justify-content:center;min-height:34px!important;padding:7px 12px!important;border:1px solid #c8dff0!important;border-radius:9px!important;background:#e5f3fe!important;color:#15568d!important;font-weight:700!important;line-height:1.2!important;cursor:pointer!important;box-shadow:none!important}
#allqa #qat .b77-action-btn:hover,#allqa #qat .b77-action-btn:focus-visible{background:#d7ecfc!important;border-color:#8dbbe4!important}
#allqa #qat .b77-action-btn:focus-visible,.b77-menu .b77-menu-item:focus-visible{outline:3px solid #79aff0!important;outline-offset:2px}
#allqa #qat .b77-action-btn svg,.b77-menu .b77-menu-item svg{display:inline-block;flex:0 0 17px;width:17px;height:17px;stroke:currentColor;fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.modal:has(#b77-safe-popup) .box{width:min(450px,94vw)!important;height:auto!important;min-height:0!important;max-height:92vh!important}
.modal:has(#b77-safe-popup) #mb{overflow-y:auto!important;max-height:calc(92vh - 90px)!important}
.modal .b77-menu{display:flex;flex-direction:column;gap:7px;padding:1px 0 3px}
.modal .b77-menu-item{width:100%;min-height:38px;padding:9px 12px;display:flex;gap:10px;align-items:center;text-align:left;border:1px solid #d6eaf7;border-radius:10px;background:#e5f3fe;color:#15568d;font-weight:700;font-family:inherit;font-size:14px;cursor:pointer;box-shadow:none}
.modal .b77-menu-item:hover{background:#d6ecfd}
.modal .b77-menu-note{font-size:12px;color:#5b7189;margin:5px 0 2px}
.modal .b77-confirm-panel{padding:10px 2px 4px;color:#223a54;line-height:1.6}
.modal .b77-confirm-actions{display:flex;justify-content:flex-end;flex-wrap:wrap;gap:8px;margin-top:16px}
.modal .b77-confirm-actions .btn{min-width:100px}
@media(max-width:650px){#allqa #qat .b77-actions-wrap{gap:5px}#allqa #qat .b77-action-btn{padding:7px 9px!important;font-size:12px!important}}


/* Shared design tokens apply only to eligible action buttons, never to layout, sidebar,
   delivery/payment input widgets, generated PDF, or any quotation data. */
button.cnr-b78-btn{
  --cnr-b78-bg:#e5f3fe;--cnr-b78-fg:#15568d;--cnr-b78-line:#c8dff0;--cnr-b78-hover:#d8ecfc;
  display:inline-flex!important;align-items:center!important;justify-content:center!important;
  vertical-align:middle!important;gap:7px!important;min-height:34px!important;
  padding:7px 12px!important;border:1px solid var(--cnr-b78-line)!important;
  border-radius:9px!important;background:var(--cnr-b78-bg)!important;
  color:var(--cnr-b78-fg)!important;font-family:inherit!important;
  font-size:13px!important;font-weight:700!important;line-height:1.3!important;
  text-align:center!important;cursor:pointer!important;box-shadow:none!important;
  text-decoration:none!important;transition:background-color .12s ease,border-color .12s ease!important;
}
button.cnr-b78-btn[data-cnr-b78-kind="edit"]{
  --cnr-b78-bg:#fff1d6;--cnr-b78-fg:#805a18;--cnr-b78-line:#eed7a5;--cnr-b78-hover:#ffe7b2;
}
#quotationFormHost #cnr-qa-save.cnr-b78-btn{
  --cnr-b78-bg:#fff1d6;--cnr-b78-fg:#805a18;--cnr-b78-line:#eed7a5;--cnr-b78-hover:#ffe7b2;
}
button.cnr-b78-btn[data-cnr-b78-kind="send"]{
  --cnr-b78-bg:#def7e9;--cnr-b78-fg:#176b46;--cnr-b78-line:#b7e1cc;--cnr-b78-hover:#c6efd9;
}
button.cnr-b78-btn[data-cnr-b78-kind="delete"]{
  --cnr-b78-bg:#fde9ec;--cnr-b78-fg:#a52d46;--cnr-b78-line:#eec8d1;--cnr-b78-hover:#fbd7dd;
}
button.cnr-b78-btn:hover:not(:disabled){background:var(--cnr-b78-hover)!important;border-color:var(--cnr-b78-fg)!important}
button.cnr-b78-btn:focus-visible{outline:3px solid #7fb2df!important;outline-offset:2px!important}
button.cnr-b78-btn:disabled{opacity:.55!important;cursor:not-allowed!important}
button.cnr-b78-btn>.cnr-b78-svg{flex:0 0 16px!important;width:16px!important;height:16px!important;display:inline-block!important;pointer-events:none!important;stroke:currentColor!important;fill:none!important;stroke-width:2!important;stroke-linecap:round!important;stroke-linejoin:round!important}
/* Buttons added by B77 (menu and QA list) use exactly the same blue-pastel tokens. */
#allqa #qat button.b77-action-btn.cnr-b78-btn{background:var(--cnr-b78-bg)!important;color:var(--cnr-b78-fg)!important;border-color:var(--cnr-b78-line)!important;min-height:34px!important}
#allqa #qat button.b77-action-btn.cnr-b78-btn:hover{background:var(--cnr-b78-hover)!important}
.modal .b77-menu-item{background:#e5f3fe;color:#15568d;border-color:#c8dff0;min-height:38px;border-radius:9px}
.modal .b77-menu-item:hover{background:#d8ecfc}
@media(max-width:650px){button.cnr-b78-btn{min-height:34px!important;padding:7px 9px!important;font-size:12px!important}}
@media(prefers-reduced-motion:reduce){button.cnr-b78-btn{transition:none!important}}


/* Darker pastel blue for major CREATE actions; preserve all dimensions, positions,
   click handlers, locked form controls and original data. */
button.cnr-b79-create.cnr-b78-btn{
  --cnr-b78-bg:#357BB9;--cnr-b78-fg:#FFFFFF;
  --cnr-b78-line:#3171AC;--cnr-b78-hover:#2D6CA7;
  background:#357BB9!important;color:#FFFFFF!important;border-color:#3171AC!important;
}
button.cnr-b79-create.cnr-b78-btn:hover:not(:disabled){background:#2D6CA7!important;border-color:#285D90!important}
button.cnr-b79-create:not(.cnr-b78-btn){background:#357BB9!important;color:#FFFFFF!important;border-color:#3171AC!important}
button.cnr-b79-create .cnr-b78-svg{stroke:#FFFFFF!important}
/* Render existing Filter button as an icon without changing its textContent or
   onclick/DOM-dependent filter and toggle logic. Keep button compact like search. */
button.cnr-b79-filter-icon{
  position:relative!important;box-sizing:border-box!important;
  width:36px!important;min-width:36px!important;max-width:36px!important;
  height:34px!important;min-height:34px!important;max-height:34px!important;
  padding:0!important;gap:0!important;font-size:0!important;
  overflow:hidden!important;vertical-align:middle!important;
  justify-content:center!important;align-items:center!important;
}
button.cnr-b79-filter-icon>*{display:none!important}
button.cnr-b79-filter-icon::before{
  content:""!important;display:block!important;width:18px!important;height:18px!important;
  flex:0 0 18px!important;background:currentColor!important;
  -webkit-mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important;
  mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important;
}
/* Named statuses only. Unrecognized/locked statuses retain original theme. */
span.status.cnr-b79-status[data-cnr-b79-status="pending"]{background:#FFF0C9!important;color:#875C00!important}
span.status.cnr-b79-status[data-cnr-b79-status="inprogress"]{background:#DDEEFF!important;color:#175A96!important}
span.status.cnr-b79-status[data-cnr-b79-status="draft"]{background:#ECEFF4!important;color:#526277!important}
span.status.cnr-b79-status[data-cnr-b79-status="sent"]{background:#DDF5E7!important;color:#176847!important}
span.status.cnr-b79-status[data-cnr-b79-status="revised"]{background:#FFE7D1!important;color:#97501A!important}
span.status.cnr-b79-status[data-cnr-b79-status="cancelled"]{background:#FCE2E8!important;color:#A22B49!important}


/* Approved main-menu background color; never style nested SQR/Quotation subforms. */
.app > aside.side { background: #030164 !important; }


/* Strictly scoped to the two native dashboard selects; preserve their layout,
   actual filtering event handlers, visible labels and role visibility. */
#dashboard > .toolbar > select:first-child,
#dashboard > .toolbar > select.admin {
  background-color:#F3FAFF !important;
  border:1px solid #D2E5F2 !important;
  border-radius:11px !important;
  color:#284C69 !important;
  font-family:inherit !important;
  font-size:14px !important;
  font-weight:500 !important;
  line-height:20px !important;
  min-height:44px !important;
  padding:10px 12px !important;
  box-sizing:border-box !important;
  box-shadow:0 1px 3px rgba(25,83,139,.04) !important;
  /* Retain native select arrow on both controls. */
  appearance:auto !important;
}
#dashboard > .toolbar > select:first-child:focus-visible,
#dashboard > .toolbar > select.admin:focus-visible {
  outline:2px solid #5796CF !important;
  outline-offset:2px !important;
}


/* #1 #2: Only ADMIN SQR right-hand actions, no duplicate creation heading */
#sqr #sqrMainTable tr>td.cnr-b83-sqr-actions{text-align:right!important;white-space:nowrap}
#sqr #sqrMainTable .cnr-b83-sqr-actions-inner{display:inline-flex;justify-content:flex-end;align-items:center;gap:7px;flex-wrap:wrap}
/* #3: REV action right for Admin; keep status position in Sales */
#revision.cnr-b83-admin-rev table tr>td:last-child{text-align:right!important}
/* #4 #13 #14: one consistent heading & compact banner spacing on both roles, no banner dimensions/asset altered */
#sqr>.title,#newqa>.title,#sqrFormHost .sqr-request-tab{font-size:23px!important;font-weight:800!important;line-height:1.35!important}
#newqa>.title{margin-bottom:5px!important}
#newqa #quotationFormHost>.main>.content{padding-top:4px!important}
#newqa #quotationFormHost .bannerwrap{margin-top:0!important}
#sqr>.title{margin-bottom:7px!important}
#sqrFormHost header.top .sqr-request-tab{min-height:0!important;padding:4px 10px!important}
#sqrFormHost #requests .sqr-banner{margin-top:-18px!important}
/* #5 #8 #10 #17: exactly one funnel graphic via CSS, preserve original control and event handlers */
button.cnr-b83-one-filter,#products button.v32-filter-btn{position:relative!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;
 width:36px!important;min-width:36px!important;max-width:36px!important;height:34px!important;min-height:34px!important;max-height:34px!important;
 box-sizing:border-box!important;padding:0!important;overflow:hidden!important;font-size:0!important;gap:0!important;line-height:0!important}
button.cnr-b83-one-filter>*,#products button.v32-filter-btn>*{display:none!important}
button.cnr-b83-one-filter::before,#products button.v32-filter-btn::before{content:""!important;display:block!important;flex:0 0 18px!important;width:18px!important;height:18px!important;
 background-color:currentColor!important;-webkit-mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important;
 mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important}
/* Sales REV: pre-existing B78 button rule overrides inline display:none, force-hide only when hidden by role */
#revision table button[aria-hidden="true"]{display:none!important}
#revision.cnr-b83-sales-rev table .cnr-b83-rev-col-hidden{display:none!important}
/* Sales status must remain visible at the right despite V104 role selector on body. */
body #revision.cnr-b83-sales-rev table .v104-status-head,body #revision.cnr-b83-sales-rev table .v104-status-cell{display:table-cell!important;visibility:visible!important}
/* #6: Quotations list ONLY. No DB status changes or Dashboard/SQR recoloring */
#allqa #qat .status.cnr-b79-status[data-cnr-b79-status="revised"],
#allqa #qat .status.cnr-b83-edited-status{background:#D9F5E5!important;color:#176B46!important;border-color:#B9E4CB!important}
/* #7 & #10: remove only the specified banner notices */
#allqa>.cnr-b83-hidden-note,#products .cnr-b83-hidden-note{display:none!important}
/* #9 #18: row replaces view button, keyboard reachable, mouse-hover feedback, touch single tap */
#customers table.table tr.cnr-b83-clickable-customer,
#cnr46-customers tr.cnr-b83-clickable-customer,
#allqa #qat tr.cnr-b83-clickable-qa{cursor:pointer!important}
#customers table.table tr.cnr-b83-clickable-customer:hover,
#cnr46-customers tr.cnr-b83-clickable-customer:hover,
#allqa #qat tr.cnr-b83-clickable-qa:hover,
#customers table.table tr.cnr-b83-clickable-customer:focus-visible,
#cnr46-customers tr.cnr-b83-clickable-customer:focus-visible,
#allqa #qat tr.cnr-b83-clickable-qa:focus-visible{background:#EAF6FE!important;outline:2px solid #8CBCE8;outline-offset:-2px}
#customers table.table .cnr-b83-hidden-view-cell,#customers table.table .cnr-b83-hidden-view-header,
#cnr46-customers .cnr-b83-hidden-view-cell,#cnr46-customers .cnr-b83-hidden-view-header{display:none!important}
#allqa #qat .cnr-b83-view-hidden{display:none!important}
#allqa #qat .b77-actions-wrap{justify-content:flex-end!important}
/* #20: Do not show eye icons in any View All / View Details action, retain password visibility controls */
button.cnr-b83-no-eye>.cnr-b78-svg,button.cnr-b83-no-eye>.cnr-b83-eye-icon{display:none!important}
/* #15 #16: Sales request REV is a prominent button left of More, not an Admin creation button */
#allqa #qat button.cnr-b83-request-rev{background:#357BB9!important;border-color:#3171AC!important;color:#fff!important}
#allqa #qat button.cnr-b83-request-rev:hover{background:#2D6CA7!important}


/* 1: only quotation cells through Status are pastel; actions retain white and a visible gap. */
#allqa #qat tr.cnr-b83-clickable-qa:hover,#allqa #qat tr.cnr-b83-clickable-qa:focus-visible{background:transparent!important;outline:none!important}
#allqa #qat tr.cnr-b83-clickable-qa:hover>td.cnr-b84-hover-zone,
#allqa #qat tr.cnr-b83-clickable-qa:focus-visible>td.cnr-b84-hover-zone{background:#EAF6FE!important;outline:none!important}
#allqa #qat tr.cnr-b83-clickable-qa:hover>td.cnr-b84-hover-first,
#allqa #qat tr.cnr-b83-clickable-qa:focus-visible>td.cnr-b84-hover-first{border-radius:12px 0 0 12px!important}
#allqa #qat tr.cnr-b83-clickable-qa:hover>td.cnr-b84-hover-last,
#allqa #qat tr.cnr-b83-clickable-qa:focus-visible>td.cnr-b84-hover-last{
 border-radius:0 12px 12px 0!important;box-shadow:inset -8px 0 0 #fff!important
}
#allqa #qat tr.cnr-b83-clickable-qa>td.actions,
#allqa #qat tr.cnr-b83-clickable-qa:hover>td.actions,
#allqa #qat tr.cnr-b83-clickable-qa:focus-visible>td.actions{background:#fff!important;outline:none!important}
/* 2: ADMIN only, reduce title-to-banner whitespace without changing the banner asset/dimensions. */
body:has(#ra.active) #newqa>.title{margin-bottom:0!important}
body:has(#ra.active) #newqa #quotationFormHost>.main>.content{padding-top:0!important}
body:has(#ra.active) #newqa #quotationFormHost .bannerwrap{margin-top:0!important}
/* 3 + 6: one and only one funnel graphic, the existing filtering onclick is preserved. */
#allqa button.cnr-b84-single-funnel,#products button.cnr-b84-single-funnel{
 display:inline-flex!important;align-items:center!important;justify-content:center!important;
 position:relative!important;flex:none!important;width:36px!important;min-width:36px!important;max-width:36px!important;
 height:34px!important;min-height:34px!important;max-height:34px!important;padding:0!important;
 overflow:hidden!important;font-size:0!important;gap:0!important;line-height:0!important
}
#allqa button.cnr-b84-single-funnel>*,#products button.cnr-b84-single-funnel>*{display:none!important}
#allqa button.cnr-b84-single-funnel::before,#products button.cnr-b84-single-funnel::before{
 content:""!important;display:block!important;width:18px!important;height:18px!important;flex:0 0 18px!important;
 background-color:currentColor!important;
 -webkit-mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important;
 mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important
}
/* 4: exactly the same creation-button theme/class as + Create Quotation, font and hover included. */
body:has(#ra.active) .cnr-b84-report-action.cnr-b79-create{color:#fff!important;width:max-content!important;white-space:nowrap!important}
/* 5: REV stays inside its existing right-side action column; no Revision logic changes. */
#revision.cnr-b83-admin-rev table td.cnr-b84-rev-action{text-align:right!important;white-space:nowrap!important}
/* 6: Product filter inputs take the established QA filter corner/border/spacing values. */
body:has(#ra.active) #products :is(.v32-filter-row,.v81-product-filter-row,.cnr-v81-product-filter-row) :is(input,select){
 border:1px solid #b8c9d6!important;border-radius:8px!important;padding:8px 9px!important;
 min-height:36px!important;box-sizing:border-box!important;margin:0 5px 0 0!important
}
/* 8: contact action references the actual, pre-existing Create theme (B79), not a sampled color. */
body:has(#ra.active) #customerModal button.cnr-b84-add-contact.cnr-b79-create{color:#fff!important}
/* 9: Edit is disabled before customer creation has succeeded. */
#cnr-b84-edit-customer:disabled{opacity:.5!important;cursor:not-allowed!important}


#sqr.cnr-r3-admin-sqr-preparing #sqrMainTable{visibility:hidden!important}
/* Hide malformed legacy 8-column Admin SQR before deferred callbacks normalize it. */
body:has(#ra.active) #sqr #sqrMainTable:not([data-cnr-live-source="production"]):has(tr:first-child > th:nth-child(7)){visibility:hidden!important}


/* Sales new quotation spacing mirrors the Admin approved 8px first-content offset. */
body:has(#rs.active) #newqa>.title{margin-bottom:0!important}
body:has(#rs.active) #newqa #quotationFormHost>main.main{padding-top:4px!important}
/* Sales customer read-only: prevent write surfaces from ever painting. */
body:has(#rs.active) .cnr-r7-sales-write-control,
body:has(#rs.active) #customers button.admin,
body:has(#rs.active) #customers button[onclick*="openCustomer"],
body:has(#rs.active) #customers button[onclick*="openNew"],
body:has(#rs.active) #cnr46-customers button.cnr46-add,
body:has(#rs.active) #cnr46-customers button[onclick*="editCustomer"],
body:has(#rs.active) #cnr70-customer-view .cnr70-edit,
body:has(#rs.active) #customerModal{display:none!important}
/* Single Filter funnel in Sales: no extra icon, triangle or repeated SVG. */
body:has(#rs.active) #customers #cnr-v77-filter-btn{
 position:relative!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;
 width:36px!important;min-width:36px!important;max-width:36px!important;
 height:34px!important;min-height:34px!important;max-height:34px!important;
 font-size:0!important;line-height:0!important;color:#174a87!important;
}
body:has(#rs.active) #customers #cnr-v77-filter-btn>*{display:none!important}
body:has(#rs.active) #customers #cnr-v77-filter-btn::after{content:none!important;display:none!important}
body:has(#rs.active) #customers #cnr-v77-filter-btn::before{
 content:""!important;display:block!important;flex:0 0 18px!important;width:18px!important;height:18px!important;
 background-color:currentColor!important;
 -webkit-mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important;
 mask:url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpath d="M4 5h16l-6 7v7l-4 2v-9Z"/%3E%3C/svg%3E') center/contain no-repeat!important;
}
/* Sales SQR actions: preserve ordering and accessible labels. */
body:has(#rs.active) #sqrMainTable td.cnr-r7-job-value{text-align:right!important;font-variant-numeric:tabular-nums}
body:has(#rs.active) #sqrMainTable tr[data-sqr-status]>td.actions{white-space:nowrap!important;text-align:right!important}
body:has(#rs.active) #sqrMainTable tr[data-sqr-status]>td.actions>button{margin-left:6px!important}
body:has(#rs.active) #sqrMainTable td.actions button svg,
body:has(#rs.active) #sqrMainTable td.actions button .cnr-b83-eye-icon{display:none!important}
/* Sales revision status must be rightmost. Columns not deleted/changed. */
body:has(#rs.active) #revision table .v104-status-head,
body:has(#rs.active) #revision table .v104-status-cell{display:table-cell!important;visibility:visible!important}
/* Reports button color must match Sales request-REV button exactly. */
body:has(#rs.active) #modal:has(#myReportResult41) #mb button,
body:has(#rs.active) #modal:has(#myReportResult) #mb .v34-report-actions button,
body:has(#rs.active) #modal .cnr-r7-sales-report-action,
body:has(#rs.active) #mb .cnr-r7-sales-report-action{
 background:#357BB9!important;border-color:#3171AC!important;color:#fff!important;font-weight:700!important;
}
body:has(#rs.active) #modal:has(#myReportResult41) #mb button:hover,
body:has(#rs.active) #modal:has(#myReportResult) #mb .v34-report-actions button:hover,
body:has(#rs.active) #modal .cnr-r7-sales-report-action:hover,
body:has(#rs.active) #mb .cnr-r7-sales-report-action:hover{background:#2D6CA7!important}
/* Exception explicitly permitted for Admin and Sales: status alignment ONLY. */
th.cnr-r7-status-heading,td.cnr-r7-status-data{text-align:left!important;vertical-align:middle!important}
td.cnr-r7-status-data>.status,td.cnr-r7-status-data>.v104-status-select{margin-left:0!important;margin-right:auto!important}
td.cnr-r7-status-data>.status,td.cnr-r7-status-data>.v104-status-select{vertical-align:middle}


/* Keep original Admin SQR rendering completely untouched. */
body:has(#rs.active) #sqr #sqrMainTable:not(:has(tr:first-child > th.cnr-r8-sales-amount-head)){
  visibility:hidden!important;
}
/* Header must align with amount figures, all inside the same column. */
body:has(#rs.active) #sqr #sqrMainTable tr:first-child > th.cnr-r8-sales-amount-head{
  text-align:center!important;
  font-variant-numeric:tabular-nums;
}
body:has(#rs.active) #sqr #sqrMainTable tr[data-sqr-status] > td.cnr-r7-job-value{
  text-align:center!important;
  font-variant-numeric:tabular-nums;
}


/* Sales revision only. Rightmost status column is created by V118; put heading and status at the right edge. */
body:has(#rs.active) #revision.v118-sales-status table th.v104-status-head,
body:has(#rs.active) #revision.v118-sales-status table td.v104-status-cell{
 text-align:right!important;vertical-align:middle!important;white-space:nowrap!important;
}
body:has(#rs.active) #revision.v118-sales-status table td.v104-status-cell select.v104-status-select{
 display:inline-block!important;margin-left:auto!important;margin-right:0!important;
}
/* No styling of other Sales status columns or any Admin status columns. */


/* Align the main right-side content area with the top of the CHAINARIS logo card. */
.main{padding-top:16px!important}
.main>.page>.title:first-child{margin-top:0!important}
/* All status columns should start from the same left edge (pattern #2), unless explicitly overridden. */
th.cnr-r10-status-heading,td.cnr-r10-status-data{
  text-align:left!important;
  vertical-align:middle!important;
}
td.cnr-r10-status-data>.status,
td.cnr-r10-status-data>select,
td.cnr-r10-status-data>.v104-status-select{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  margin-left:0!important;
  margin-right:auto!important;
  vertical-align:middle!important;
}
/* Keep the explicit Sales revision exception: status remains at rightmost and aligned right. */
body:has(#rs.active) #revision.v118-sales-status table th.v104-status-head,
body:has(#rs.active) #revision.v118-sales-status table td.v104-status-cell{
  text-align:right!important;
}
body:has(#rs.active) #revision.v118-sales-status table td.v104-status-cell>.status,
body:has(#rs.active) #revision.v118-sales-status table td.v104-status-cell>select,
body:has(#rs.active) #revision.v118-sales-status table td.v104-status-cell>.v104-status-select{
  margin-left:auto!important;
  margin-right:0!important;
  justify-content:flex-end!important;
}
/* All Sales/Admin SQR status headers and pills share an exact left start. */
#sqr #sqrMainTable tr:first-child>th:nth-child(5),
#sqr #sqrMainTable tr[data-sqr-status]>td:nth-child(5){
 text-align:left!important;vertical-align:middle!important;padding-left:10px!important;
}
#sqr #sqrMainTable tr[data-sqr-status]>td:nth-child(5)>.status{
 margin-left:0!important;margin-right:auto!important;
}


body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable tr:first-child > th:nth-child(5){
  padding-left:4px!important;
  padding-right:16px!important;
}


/* This selector does not match Admin. It changes text indentation only, not column width or badges. */
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable tr:first-child > th:nth-child(5){
  text-indent:var(--cnr-r13-sqr-status-indent, 0px)!important;
}


/* Original last status cell / select remains untouched and right aligned.  Match
   the start of its visible select with the start of the header label. */
body:has(#rs.active) #revision.v118-sales-status table th.v104-status-head > .cnr-r14-heading-label {
  display:inline-block!important;
  width:var(--cnr-r14-control-width,81px)!important;
  text-align:left!important;
  text-indent:0!important;
  white-space:nowrap!important;
  vertical-align:middle!important;
}


#cnr-r15-sqr-modal{display:none;position:fixed;inset:0;background:rgba(14,30,49,.58);z-index:999995;
  padding:24px;align-items:center;justify-content:center;font-family:Arial,Tahoma,sans-serif;color:#182c49}
#cnr-r15-sqr-modal.cnr-r15-open{display:flex}
#cnr-r15-sqr-modal,#cnr-r15-sqr-modal *{box-sizing:border-box}
#cnr-r15-sqr-modal .cnr-r15-window{width:min(920px,96vw);max-height:min(92vh,980px);background:#fff;border-radius:8px;
  box-shadow:0 18px 70px rgba(9,24,49,.25);display:flex;flex-direction:column;overflow:hidden}
#cnr-r15-sqr-modal .cnr-r15-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;
  padding:12px 16px;border-bottom:1px solid #d7e4ef;background:linear-gradient(100deg,#f4f8fd,#ffffff);font-size:19px;font-weight:800}
#cnr-r15-sqr-modal .cnr-r15-x{border:0;background:transparent;cursor:pointer;font-size:25px;color:#66758a;padding:2px 7px}
#cnr-r15-sqr-modal .cnr-r15-body{overflow:auto;padding:14px 17px 8px;flex:1;min-height:0}
#cnr-r15-sqr-modal .cnr-r15-summary{display:flex;gap:8px;justify-content:space-between;align-items:flex-start;flex-wrap:wrap;margin:0 0 13px}
#cnr-r15-sqr-modal .cnr-r15-sqr-no{font-weight:800;color:#122d56;font-size:19px;margin-right:8px}
#cnr-r15-sqr-modal .cnr-r15-badge{display:inline-block;padding:4px 10px;border-radius:999px;background:#e5f5ed;color:#277957;font-size:12px;font-weight:700}
#cnr-r15-sqr-modal .cnr-r15-timing{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin-top:10px}
#cnr-r15-sqr-modal .cnr-r15-timing label{display:block;font-size:12px;color:#68778a;margin-bottom:5px}
#cnr-r15-sqr-modal .cnr-r15-pdf{display:inline-flex;align-items:center;justify-content:center;text-decoration:none;white-space:nowrap;background:#fff;border:1px solid #b9cde2;color:#153e75;border-radius:5px;padding:10px 13px;font-weight:700}
#cnr-r15-sqr-modal .cnr-r15-pdf:disabled{color:#8495a8;background:#f6f9fc;border-color:#dce5ef;cursor:not-allowed}
#cnr-r15-sqr-modal .cnr-r15-section{margin:12px 0 0;border:1px solid #e1e8f0;border-radius:5px;overflow:hidden}
#cnr-r15-sqr-modal .cnr-r15-section-title{background:linear-gradient(90deg,#dfedf8,#e7f2f8);color:#12345e;font-weight:800;padding:9px 11px;font-size:13px}
#cnr-r15-sqr-modal .cnr-r15-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 26px;padding:12px 14px}
#cnr-r15-sqr-modal .cnr-r15-field{display:grid;grid-template-columns:minmax(95px,35%) minmax(0,1fr);gap:8px;font-size:13px;align-items:start;overflow-wrap:anywhere}
#cnr-r15-sqr-modal .cnr-r15-field b{color:#243547}
#cnr-r15-sqr-modal table{width:100%;border-collapse:collapse;font-size:12px;color:#1b2f45}
#cnr-r15-sqr-modal th,#cnr-r15-sqr-modal td{padding:7px 8px;border:1px solid #e0e7ed;text-align:left;vertical-align:middle}
#cnr-r15-sqr-modal th{background:#f1f5f8;color:#21384e;font-weight:700}
#cnr-r15-sqr-modal .cnr-r15-num{text-align:right;font-variant-numeric:tabular-nums}
#cnr-r15-sqr-modal .cnr-r15-center{text-align:center}
#cnr-r15-sqr-modal .cnr-r15-bottom{display:grid;grid-template-columns:1fr 1fr;gap:15px}
#cnr-r15-sqr-modal .cnr-r15-bottom>.cnr-r15-section:first-child .cnr-r15-fields{grid-template-columns:1fr;gap:7px}
#cnr-r15-sqr-modal .cnr-r15-empty{color:#79889a;text-align:center;padding:16px 8px}
#cnr-r15-sqr-modal .cnr-r15-footer{display:flex;align-items:center;justify-content:flex-end;gap:10px;padding:11px 17px;border-top:1px solid #e2e9f1}
#cnr-r15-sqr-modal .cnr-r15-close{border:0;padding:9px 26px;background:#edf0f3;color:#263d54;border-radius:5px;cursor:pointer}
#cnr-r15-sqr-modal .cnr-r15-quote{background:#2e79b7;color:#fff;border:0;padding:9px 15px;border-radius:5px;cursor:pointer}
@media(max-width:680px){#cnr-r15-sqr-modal{padding:8px}#cnr-r15-sqr-modal .cnr-r15-window{width:100%;max-height:96vh}
  #cnr-r15-sqr-modal .cnr-r15-body{padding:9px}#cnr-r15-sqr-modal .cnr-r15-fields,#cnr-r15-sqr-modal .cnr-r15-bottom{grid-template-columns:1fr}
  #cnr-r15-sqr-modal .cnr-r15-timing{grid-template-columns:repeat(2,minmax(0,1fr))}
  #cnr-r15-sqr-modal .cnr-r15-section table{min-width:520px}
  #cnr-r15-sqr-modal .cnr-r15-table-scroll{overflow-x:auto}}


#cnr-r15-sqr-modal .cnr-r15-window{width:min(930px,97vw);max-height:min(96vh,1180px)}
#cnr-r15-sqr-modal .cnr-r15-body{padding:0;background:#f6f9fc}
#cnr-r15-sqr-modal .cnr-r18-pdf-tools{position:sticky;top:0;z-index:2;display:flex;justify-content:flex-end;align-items:center;padding:8px 15px;background:#f8fbfe;border-bottom:1px solid #e0e7ef}
#cnr-r15-sqr-modal .cnr-r18-pdf-tools .cnr-r15-pdf{padding:7px 12px;font-size:12px;cursor:pointer}
#cnr-r15-sqr-modal .cnr-r18-paper-container{padding:12px 10px 24px;text-align:center;overflow-x:auto}
#cnr-r15-sqr-modal .cnr-r18-paper-iframe{display:block;border:0;box-shadow:0 3px 15px rgba(15,43,70,.1);background:#fff;margin:0 auto;width:min(794px,100%);height:1124px}
#cnr-r15-sqr-modal .cnr-r18-status{color:#3a516a;font-size:13px;text-align:center;padding:26px 15px;background:#fff}
@media(max-width:820px){#cnr-r15-sqr-modal .cnr-r18-paper-container{padding:6px 0 12px}#cnr-r15-sqr-modal .cnr-r18-paper-iframe{min-width:794px}#cnr-r15-sqr-modal .cnr-r18-paper-container{text-align:left}}


/* Restrict changes to the Production search popover and Delivery > Other.
   No navigation/sidebar/dashboard color/layout selectors are touched. */
.cnr-r19-suggestion-menu {position:fixed;z-index:2147483000;min-width:180px;max-height:260px;overflow-y:auto;
 background:#fff;border:1px solid #aac6df;border-radius:9px;padding:3px;box-shadow:0 8px 22px rgba(5,30,70,.2)}
.cnr-r19-suggestion-menu[hidden] {display:none!important}
.cnr-r19-suggestion-option {display:block;width:100%;text-align:left;white-space:normal;
 border:0;border-bottom:1px solid #ebeff3;border-radius:3px;background:#fff;
 color:#18304f;padding:9px 10px;font:inherit;cursor:pointer}
.cnr-r19-suggestion-option:hover,.cnr-r19-suggestion-option:focus {background:#e5f3ff;outline:1px solid #7fb6ee}
.cnr-r19-suggestion-option small{display:block;color:#536b84;font-size:12px;margin-top:2px}
/* Override only historical rules hiding the explicit Other item controls. */
#quotationFormHost [data-q20="delivery"].cnr-stage-other-active > [data-items].q20-delivery-items {display:flex!important;flex-direction:column!important;gap:8px!important;visibility:visible!important}
#quotationFormHost [data-q20="delivery"]:not(.cnr-stage-other-active) > [data-items].q20-delivery-items {display:none!important}
#quotationFormHost [data-q20="delivery"].cnr-stage-other-active > .v37-delivery-items,
#quotationFormHost [data-q20="delivery"].cnr-stage-other-active > .v36-delivery-items,
#quotationFormHost [data-q20="delivery"].cnr-stage-other-active > .check14-delivery-items {display:none!important}
#sqrFormHost .delivery-block .v37-delivery-items.cnr-stage-other-active {display:block!important;visibility:visible!important;width:100%!important;margin:9px 0 11px!important}
#sqrFormHost .delivery-block .v37-delivery-items:not(.cnr-stage-other-active) {display:none!important}
#sqrFormHost .delivery-block .v37-delivery-items .cnr-stage-other-add,
#quotationFormHost [data-q20="delivery"] [data-items] .cnr-stage-other-add {
 display:inline-flex!important;visibility:visible!important;position:static!important;pointer-events:auto!important;
 opacity:1!important;width:max-content!important;margin:8px 0!important;z-index:2!important}
/* Hide older duplicate Admin-only add control in the same section. */
#quotationFormHost [data-q20="delivery"] [data-items] [data-b74-add-delivery] {display:none!important}


/* Both sidebar search pages: preserve the approved menu color and behavior; make selection distinct and rounded. */
#menu > button[data-id="customers"].active,
#menu > button[data-id="products"].active,
#menu > button[data-id="customers"]:hover,
#menu > button[data-id="products"]:hover {
  background:#ffffff26!important;
  border-radius:12px!important;
}
#menu > button[data-id="customers"]:focus-visible,
#menu > button[data-id="products"]:focus-visible {
  background:#ffffff26!important;
  border-radius:12px!important;
  outline:2px solid #e5f3fe!important;
  outline-offset:2px!important;
}
/* Cell backgrounds are required: the existing table-row hover outline makes a rectangular bar.
   Limit styling to the existing customer rows; no data, click, or navigation functions change. */
#customers tr.cnr-b83-clickable-customer:hover,
#customers tr.cnr-b83-clickable-customer:focus-visible,
#cnr46-customers tr.cnr-b83-clickable-customer:hover,
#cnr46-customers tr.cnr-b83-clickable-customer:focus-visible {
  background:transparent!important;
  outline:none!important;
}
#customers tr.cnr-b83-clickable-customer:hover > td:not(.cnr-b83-hidden-view-cell),
#customers tr.cnr-b83-clickable-customer:focus-visible > td:not(.cnr-b83-hidden-view-cell),
#cnr46-customers tr.cnr-b83-clickable-customer:hover > td:not(.cnr-b83-hidden-view-cell),
#cnr46-customers tr.cnr-b83-clickable-customer:focus-visible > td:not(.cnr-b83-hidden-view-cell),
#cnr46-products .cnr46-grid tbody > tr:hover > td {
  background:#EAF6FE!important;
  outline:none!important;
}
/* Use separate borders only within the two search tables to allow CSS cell corner clipping. */
#customers table.table,
#cnr46-customers .cnr46-grid table,
#cnr46-products .cnr46-grid table {border-collapse:separate!important;border-spacing:0!important;}
#customers tr.cnr-b83-clickable-customer:hover > td:first-child,
#customers tr.cnr-b83-clickable-customer:focus-visible > td:first-child,
#cnr46-customers tr.cnr-b83-clickable-customer:hover > td:first-child,
#cnr46-customers tr.cnr-b83-clickable-customer:focus-visible > td:first-child,
#cnr46-products .cnr46-grid tbody > tr:hover > td:first-child {
  border-radius:12px 0 0 12px!important;
}
/* The customer row's action cell is hidden; round the last *visible* cell. */
#customers tr.cnr-b83-clickable-customer:hover > td:last-child:not(.cnr-b83-hidden-view-cell),
#customers tr.cnr-b83-clickable-customer:focus-visible > td:last-child:not(.cnr-b83-hidden-view-cell),
#customers tr.cnr-b83-clickable-customer:hover > td:has(+td.cnr-b83-hidden-view-cell),
#customers tr.cnr-b83-clickable-customer:focus-visible > td:has(+td.cnr-b83-hidden-view-cell),
#cnr46-customers tr.cnr-b83-clickable-customer:hover > td:last-child:not(.cnr-b83-hidden-view-cell),
#cnr46-customers tr.cnr-b83-clickable-customer:focus-visible > td:last-child:not(.cnr-b83-hidden-view-cell),
#cnr46-customers tr.cnr-b83-clickable-customer:hover > td:has(+td.cnr-b83-hidden-view-cell),
#cnr46-customers tr.cnr-b83-clickable-customer:focus-visible > td:has(+td.cnr-b83-hidden-view-cell),
#cnr46-products .cnr46-grid tbody > tr:hover > td:last-child {
  border-radius:0 12px 12px 0!important;
}


/* The old sample product table uses #products .panel > table.table, not #cnr46-products.
   Match the approved customer blue / 12px rounded cells; header is excluded. */
#products > .panel > table.table,
#cnr46-products .cnr46-grid table {
  border-collapse:separate!important;
  border-spacing:0!important;
}
#products > .panel > table.table > tbody > tr:hover > td,
#products > .panel > table.table > tbody > tr:focus-within > td,
#cnr46-products .cnr46-grid table > tbody > tr:hover > td,
#cnr46-products .cnr46-grid table > tbody > tr:focus-within > td {
  background:#EAF6FE!important;
  outline:none!important;
}
#products > .panel > table.table > tbody > tr:hover > td:first-child,
#products > .panel > table.table > tbody > tr:focus-within > td:first-child,
#cnr46-products .cnr46-grid table > tbody > tr:hover > td:first-child,
#cnr46-products .cnr46-grid table > tbody > tr:focus-within > td:first-child {
  border-radius:12px 0 0 12px!important;
}
#products > .panel > table.table > tbody > tr:hover > td:last-child,
#products > .panel > table.table > tbody > tr:focus-within > td:last-child,
#cnr46-products .cnr46-grid table > tbody > tr:hover > td:last-child,
#cnr46-products .cnr46-grid table > tbody > tr:focus-within > td:last-child {
  border-radius:0 12px 12px 0!important;
}


#menu button[data-id="allqa"] > .badge{display:none!important}


#cnr4a-panel-qa,
#cnr4a-panel-sqr,
#cnr5f-panel,
#cnr5h-panel{display:none!important}


#quotationFormHost #cnr-qa-save.cnr-b78-btn{
  --cnr-b78-bg:#e5f3fe;--cnr-b78-fg:#15568d;--cnr-b78-line:#c8dff0;--cnr-b78-hover:#d8ecfc;
}
#quotationFormHost #cnr-qa-draft-save.cnr-b78-btn{
  --cnr-b78-bg:#fff1d6;--cnr-b78-fg:#805a18;--cnr-b78-line:#eed7a5;--cnr-b78-hover:#ffe7b2;
}
body:has(#rs.active) #cnr5h-panel{display:none!important}


body:has(#rs.active):not(:has(#ra.active)) #sqr > .panel:has(#sqrMainTable){overflow-x:auto}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable{
  table-layout:fixed!important;
  min-width:850px;
}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable tr:first-child > th:nth-child(1){width:13%}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable tr:first-child > th:nth-child(2){width:29%}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable tr:first-child > th:nth-child(3){width:18%}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable tr:first-child > th:nth-child(4){width:18%}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable tr:first-child > th:nth-child(5){width:11%}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable tr:first-child > th:nth-child(6){width:11%}
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable tr:first-child > th:nth-child(4),
body:has(#rs.active):not(:has(#ra.active)) #sqr #sqrMainTable tr[data-cnr-live-request-id] > td:nth-child(4){
  text-align:center!important;
  font-variant-numeric:tabular-nums;
}
