/* HayOrder v1.1.73 – Footer-Layout korrigiert, X-Schließer bereinigt, Popup-Border neutral */

/* =========================================================
   1) BESTELLDETAIL: Desktop/Laptop exakt 3 gleich große Aktionen
   ========================================================= */
body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-template-areas:"primary cancel print"!important;
  align-items:stretch!important;
  justify-content:end!important;
  gap:10px!important;
  width:min(100%,690px)!important;
  margin-left:auto!important;
}
body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-primary-form{
  grid-area:primary!important;
}
body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-cancel-form{
  grid-area:cancel!important;
}
body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-print-button{
  grid-area:print!important;
}
body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-primary-form,
body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-cancel-form,
body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-print-button{
  display:block!important;
  flex:none!important;
  width:100%!important;
  min-width:0!important;
  max-width:none!important;
  margin:0!important;
}
body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-primary-form > button,
body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-cancel-form > button,
body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-print-button{
  width:100%!important;
  min-width:0!important;
  max-width:none!important;
  min-height:48px!important;
  margin:0!important;
  padding:0 15px!important;
  border-width:1px!important;
  border-radius:13px!important;
  font-size:12.5px!important;
  line-height:1.15!important;
  font-weight:700!important;
  white-space:normal!important;
  text-align:center!important;
}

/* =========================================================
   2) HANDY: Statusaktion allein volle Breite, unten 50 / 50
   ========================================================= */
@media(max-width:700px){
  body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons{
    display:grid!important;
    grid-template-columns:minmax(0,1fr) minmax(0,1fr)!important;
    grid-template-areas:
      "primary primary"
      "cancel print"!important;
    gap:8px!important;
    width:100%!important;
    max-width:none!important;
    margin:0!important;
  }
  body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-primary-form{
    grid-area:primary!important;
    grid-column:1/-1!important;
    width:100%!important;
  }
  body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-cancel-form{
    grid-area:cancel!important;
    grid-column:1!important;
    width:100%!important;
  }
  body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-print-button{
    grid-area:print!important;
    grid-column:2!important;
    width:100%!important;
  }
  body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-primary-form > button,
  body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-cancel-form > button,
  body #orders-ajax-root.ho-orders-173 .ho124-detail .ho68-footer-buttons > .ho68-print-button{
    min-height:50px!important;
    font-size:12.5px!important;
  }
}

/* =========================================================
   3) SCHLIESSER: genau ein X, kreisrund und optisch mittig
   Alle Operator-Popups verwenden bereits ein echtes × im Markup.
   Deshalb keine Pseudo-Glyphe mehr erzeugen.
   ========================================================= */
body :is(
  .ho-new-close,
  .ho56-close-detail,
  .category-dialog-close,
  .catalog-editor-close,
  .extras-modal-close,
  .ho63-close,
  .ho-modal-close
)::before,
body :is(
  .ho-new-close,
  .ho56-close-detail,
  .category-dialog-close,
  .catalog-editor-close,
  .extras-modal-close,
  .ho63-close,
  .ho-modal-close
)::after,
body .ho-res-dialog-head>[data-res-close][aria-label]::before,
body .ho-res-dialog-head>[data-res-close][aria-label]::after{
  content:none!important;
  display:none!important;
}

body :is(
  .ho-new-close,
  .ho56-close-detail,
  .category-dialog-close,
  .catalog-editor-close,
  .extras-modal-close,
  .ho63-close,
  .ho-modal-close
),
body .ho-res-dialog-head>[data-res-close][aria-label]{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:40px!important;
  min-width:40px!important;
  height:40px!important;
  min-height:40px!important;
  padding:0 0 2px!important;
  border:1px solid rgba(139,159,179,.30)!important;
  border-radius:50%!important;
  color:#eef3f7!important;
  background:rgba(28,40,52,.90)!important;
  font-family:Arial,Helvetica,sans-serif!important;
  font-size:25px!important;
  line-height:1!important;
  font-weight:400!important;
  text-align:center!important;
  text-indent:0!important;
  overflow:hidden!important;
  box-shadow:none!important;
  transform:none!important;
}
body #orders-ajax-root.ho-orders-173 .ho124-detail .ho56-close-detail{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:40px!important;
  min-width:40px!important;
  height:40px!important;
  min-height:40px!important;
  padding:0 0 2px!important;
  border-radius:50%!important;
  color:#eef3f7!important;
  font-family:Arial,Helvetica,sans-serif!important;
  font-size:25px!important;
  line-height:1!important;
  font-weight:400!important;
  overflow:hidden!important;
}
body.theme-light :is(.ho-new-close,.ho56-close-detail,.category-dialog-close,.catalog-editor-close,.extras-modal-close,.ho63-close,.ho-modal-close),
body.theme-light .ho-res-dialog-head>[data-res-close][aria-label],
body.theme-light #orders-ajax-root.ho-orders-173 .ho124-detail .ho56-close-detail{
  color:#273746!important;
  background:#f5f8fa!important;
  border-color:#cbd6df!important;
}

/* =========================================================
   4) DETAIL-POPUP: Außenrahmen neutral und überall gleich stark
   ========================================================= */
body #orders-ajax-root.ho-orders-173.ho59-modal-ready .ho124-detail:not([hidden]){
  border:1px solid rgba(101,121,141,.38)!important;
  border-top:1px solid rgba(101,121,141,.38)!important;
  border-right:1px solid rgba(101,121,141,.38)!important;
  border-bottom:1px solid rgba(101,121,141,.38)!important;
  border-left:1px solid rgba(101,121,141,.38)!important;
  box-shadow:0 42px 118px rgba(0,0,0,.62),0 8px 24px rgba(0,0,0,.20),0 0 0 1px rgba(255,255,255,.02)!important;
}
body.theme-light #orders-ajax-root.ho-orders-173.ho59-modal-ready .ho124-detail:not([hidden]){
  border-color:rgba(117,134,152,.40)!important;
  box-shadow:0 34px 92px rgba(16,24,40,.17),0 8px 24px rgba(16,24,40,.08),0 0 0 1px rgba(255,255,255,.62)!important;
}
