/* GFLEX TEST Stage 041 — restrained, accessible action hierarchy */
#appRoot section.panel button.action:not(:disabled),
#appRoot section.panel button.finishLoadBtn:not(:disabled),
#appRoot section.panel button.routeMoveBtn:not(:disabled),
#appRoot section.panel button.routingFixBtn:not(:disabled),
#appRoot section.panel button.routingTransferBtn:not(:disabled) {
  background:#1769b5!important;
  border:1px solid #247bc8!important;
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
  box-shadow:0 2px 5px rgba(15,52,90,.12)!important;
}
#appRoot section.panel #officePrepareBtn:not(:disabled),
#appRoot section.panel #sendBranchTransferBtn:not(:disabled){
  background:#ce2f45!important;
  border-color:#dc4659!important;
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
}
#appRoot section.panel #processExpectedExcelBtn:not(:disabled),
#appRoot section.panel #processPrepareExcelBtn:not(:disabled),
#appRoot section.panel #saveMissingExpectedInfoBtn:not(:disabled),
#appRoot section.panel #checkIncomingTransferBtn:not(:disabled),
#appRoot section.panel #finishLoadBtn:not(:disabled),
#appRoot section.panel #verifyExpectedBtn:not(:disabled){
  background:#087f77!important;
  border-color:#14998e!important;
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
}
/* A DISABLED export is still readable and recognisable on pale surfaces. */
#appRoot section.panel button:disabled,
#appRoot section.panel button.exportBtn:disabled,
#appRoot section.panel button.smallExport:disabled,
#appRoot section.panel button.excelSecondaryBtn:disabled,
#appRoot section.panel button.routingToggleBtn:disabled {
  opacity:1!important;
  filter:none!important;
  background:#e4eaf1!important;
  color:#40516a!important;
  -webkit-text-fill-color:#40516a!important;
  border:1px solid #aab8c8!important;
  box-shadow:none!important;
  text-shadow:none!important;
  cursor:not-allowed!important;
}
#appRoot section.panel button:disabled *,
#appRoot section.panel button.exportBtn:disabled *,
#appRoot section.panel button.smallExport:disabled *{
  opacity:1!important;
  color:#40516a!important;
  -webkit-text-fill-color:#40516a!important;
}
#appRoot section.panel .routingActions button:disabled,
#appRoot section.panel #exportExpectedMissingBtn:disabled,
#appRoot section.panel #downloadPrepareResultBtn:disabled {
  min-width:110px;
}
/* Stage 041 office metadata dialog */
.gflex041Backdrop{position:fixed;inset:0;z-index:250300;background:rgba(5,19,41,.72);display:flex;align-items:center;justify-content:center;padding:14px;backdrop-filter:blur(5px)}
.gflex041Dialog{width:min(520px,100%);max-height:min(94vh,850px);overflow-y:auto;background:#fff;color:#17365b;border-radius:19px;box-shadow:0 20px 80px rgba(0,0,0,.3);padding:23px;border-top:5px solid #dda027}
.gflex041Dialog h2{font-size:21px;font-weight:900;line-height:1.25;margin:0 0 9px;color:#112c50}
.gflex041Code{font-size:17px;font-family:ui-monospace,monospace;color:#084891;font-weight:900;margin:7px 0 12px;overflow-wrap:anywhere}
.gflex041Warning{border:1px solid #eecb75;border-radius:10px;padding:10px 12px;background:#fff8e8;color:#684c14;font-weight:700;line-height:1.5;font-size:13px;margin-bottom:12px}
.gflex041Dialog label{display:block;font-size:13px;color:#244360;font-weight:800;margin:11px 0 5px}
.gflex041Dialog input,.gflex041Dialog textarea{width:100%;box-sizing:border-box;padding:12px;border-radius:9px;border:1px solid #aabbd1;background:#fff;color:#122e4d;-webkit-text-fill-color:#122e4d;font-family:inherit;font-size:15px;min-height:46px}
.gflex041Dialog textarea{min-height:80px;resize:vertical}
.gflex041Dialog input:focus-visible,.gflex041Dialog textarea:focus-visible{outline:3px solid #ffd166;outline-offset:1px}
.gflex041Hint{font-size:12px;color:#59718a;line-height:1.45;margin:9px 0}
.gflex041Actions{display:flex;flex-wrap:wrap;gap:9px;margin-top:18px}
.gflex041Actions button{flex:1 1 140px;min-height:47px;padding:11px 14px;border-radius:10px;font-size:14px;font-weight:850;border:1px solid #b4c3d3;cursor:pointer}
.gflex041Cancel{background:#edf2f8;color:#294665}
.gflex041Continue{background:#1769b5;color:#fff;border-color:#1769b5!important}
.gflex041Error{margin-top:8px;color:#a2192a;font-weight:750;font-size:13px;min-height:1em}
.gflex041Dialog button:focus-visible{outline:3px solid #ffc94b;outline-offset:2px}
@media(max-width:500px){.gflex041Dialog{padding:17px}.gflex041Dialog h2{font-size:18px}}
/* Last theme wins; server API remains Version 038. */
#appRoot .testVersion::after{content:" · UI 041"!important;font-weight:950;color:#e2edff!important}

/* Always display the final confirmation ABOVE the metadata dialog. */
.gflexConfirmCover{z-index:250600!important}
