/* NOC Rental · Contract mobile toolbar: compact, consistent, touch-friendly.
   Screen-only; it must never affect legal contract printing or PDF export. */
@media screen and (max-width:760px){
  html[data-theme] body #contractEditor{
    padding:14px!important;
    scroll-margin-top:84px;
  }
  html[data-theme] body #contractEditor>.section-head{
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    column-gap:10px!important;
    row-gap:12px!important;
    width:100%!important;
    min-width:0!important;
    align-items:start!important;
    margin-bottom:12px!important;
  }
  html[data-theme] body #contractEditor>.section-head>div:first-child{
    grid-column:1!important;grid-row:1!important;min-width:0!important;
    max-width:100%!important;
  }
  html[data-theme] body #contractEditor #contractEditorTitle{
    font-size:clamp(1.12rem,4.6vw,1.35rem)!important;
    line-height:1.22!important;margin:1px 0 5px!important;
    overflow-wrap:anywhere!important;
  }
  html[data-theme] body #contractEditor #contractVersion{
    font-size:.76rem!important;line-height:1.4!important;
    margin:0!important;min-height:0!important;color:var(--muted)!important;
    overflow-wrap:anywhere!important;
  }
  html[data-theme] body #contractEditor>.section-head>.contract-editor-actions{
    display:contents!important;
  }
  html[data-theme] body #contractEditor #contractClose{
    grid-column:2!important;grid-row:1!important;
    justify-self:end!important;align-self:start!important;
    width:auto!important;min-width:78px!important;max-width:105px!important;
    min-height:40px!important;height:40px!important;
    padding:8px 12px!important;font-size:.81rem!important;
    font-weight:600!important;
  }
  html[data-theme] body #contractEditor #contractPdf,
  html[data-theme] body #contractEditor #contractPrint{
    grid-row:2!important;
    width:100%!important;min-width:0!important;max-width:100%!important;
    height:44px!important;min-height:44px!important;max-height:none!important;
    padding:8px 9px!important;font-size:.86rem!important;line-height:1.2!important;
    font-weight:650!important;letter-spacing:0!important;
    border-radius:10px!important;white-space:normal!important;
    text-align:center!important;
    box-shadow:none!important;transform:none!important;filter:none!important;
  }
  html[data-theme] body #contractEditor #contractPdf{
    grid-column:1!important;
    justify-self:stretch!important;
  }
  html[data-theme] body #contractEditor #contractPrint{
    grid-column:2!important;
    background:#14854b!important;border-color:#14854b!important;
    color:#fff!important;
  }
  html[data-theme] body #contractEditor #contractSave[hidden]{
    display:none!important;
  }
  html[data-theme] body #contractEditor .contract-signature-panel{
    padding:12px!important;
    margin:0 0 15px!important;
    min-width:0!important;
    border-radius:12px!important;
  }
  html[data-theme] body #contractEditor .contract-signature-row{
    display:flex!important;flex-direction:column!important;
    align-items:stretch!important;gap:10px!important;
    min-width:0!important;width:100%!important;
  }
  html[data-theme] body #contractEditor .contract-signature-row>div:first-child{
    min-width:0!important;
  }
  html[data-theme] body #contractEditor .contract-signature-row>div:first-child>strong{
    font-size:.96rem!important;line-height:1.25!important;
  }
  html[data-theme] body #contractEditor .contract-signature-status{
    font-size:.84rem!important;line-height:1.4!important;
    overflow-wrap:anywhere!important;
  }
  html[data-theme] body #contractEditor .contract-signature-row>.actions{
    display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;
    width:100%!important;min-width:0!important;max-width:100%!important;
    gap:8px!important;margin:0!important;justify-content:stretch!important;
  }
  html[data-theme] body #contractEditor .contract-signature-row>.actions>button{
    width:100%!important;min-width:0!important;max-width:100%!important;
    height:44px!important;min-height:44px!important;
    margin:0!important;padding:8px 7px!important;
    font-size:.82rem!important;line-height:1.15!important;
    font-weight:650!important;border-radius:10px!important;
    letter-spacing:0!important;white-space:normal!important;
    box-shadow:none!important;transform:none!important;
  }
  html[data-theme] body #contractEditor #contractSignatureRevoke:not([hidden]){
    grid-column:1/-1!important;
  }
  html[data-theme] body #contractEditor .contract-signature-recipient{
    margin:10px 0!important;padding:10px!important;
  }
  html[data-theme] body #contractEditor .contract-signature-recipient label{
    font-size:.80rem!important;line-height:1.35!important;
  }
  html[data-theme] body #contractEditor .contract-editor>h3{
    font-size:1.02rem!important;margin:16px 0 10px!important;
  }
  html[data-theme] body #contractEditor .contract-editor>.form-grid{
    gap:10px!important;
  }
}
@media screen and (max-width:355px){
  html[data-theme] body #contractEditor #contractClose{
    min-width:66px!important;padding:8px!important;
  }
  html[data-theme] body #contractEditor #contractPdf,
  html[data-theme] body #contractEditor #contractPrint,
  html[data-theme] body #contractEditor .contract-signature-row>.actions>button{
    font-size:.76rem!important;padding-inline:5px!important;
  }
}
