/* GNS v2.7.185 — Document selection: no overlap, anchored menus, searchable GNS values. */
section.warehouse-document-filters{
 position:relative!important;overflow:visible!important;isolation:isolate;
}
section.warehouse-document-filters .gns-doc-filter-prefs{
 position:relative!important;z-index:1!important;box-sizing:border-box!important;
 margin:7px 0 9px!important;clear:both;
}
section.warehouse-document-filters .form-grid{
 display:grid!important;grid-template-columns:repeat(auto-fit,minmax(165px,1fr))!important;
 grid-auto-flow:row!important;align-items:start!important;
 gap:9px 10px!important;max-height:none!important;min-height:0!important;
 overflow:visible!important;padding-right:0!important;
}
section.warehouse-document-filters .form-grid.gns-extra-open{
 overflow:visible!important;max-height:none!important;
}
section.warehouse-document-filters .form-grid>label,
section.warehouse-document-filters .form-grid>.gns-document-filter-partner{
 min-width:0!important;min-height:51px!important;max-width:100%!important;
 position:relative!important;align-self:start!important;overflow:visible!important;
}
section.warehouse-document-filters .form-grid>label>span{
 display:block;min-height:13px;line-height:1.25!important;
}
section.warehouse-document-filters .gns-doc-filter-prefs{
 max-height:230px!important;overflow:auto!important;
}
section.warehouse-document-filters .gns-document-filter-partner .gns-shared-partner-picker{
 position:relative!important;overflow:visible!important;
}
section.warehouse-document-filters .gns-document-filter-partner .gns-shared-partner-quick{
 position:absolute!important;top:calc(100% + 3px)!important;
 left:0!important;right:auto!important;bottom:auto!important;
 width:min(380px,max(100%,230px))!important;
 max-width:min(380px,calc(100vw - 35px))!important;
 min-height:0!important;max-height:250px!important;
 overflow-y:auto!important;padding:5px!important;margin:0!important;
 background:#fff!important;border:1px solid #94b1d2!important;border-radius:8px!important;
 box-shadow:0 12px 28px #193c5b30!important;z-index:1600!important;
}
section.warehouse-document-filters .gns-document-filter-partner .gns-shared-partner-quick button{
 position:static!important;display:flex!important;flex-direction:column!important;
 width:100%!important;height:auto!important;min-height:42px!important;
 background:#fff!important;text-align:left!important;align-items:stretch!important;
 border:0!important;border-radius:4px!important;font-size:12px!important;
 color:#23455d!important;padding:6px 9px!important;white-space:normal!important;
}
section.warehouse-document-filters .gns-document-filter-partner .gns-shared-partner-quick button small{
 display:block!important;color:#697a8f!important;font-size:10px!important;line-height:1.3!important;
}
section.warehouse-document-filters .gns-document-filter-partner .gns-shared-partner-quick button:hover{
 background:#eef5fd!important;
}
section.warehouse-document-filters .gns-gdf-lookup-box{
 position:relative!important;display:block!important;min-width:0!important;width:100%!important;
 overflow:visible!important;isolation:isolate;
}
section.warehouse-document-filters .gns-gdf-lookup-text{
 display:block!important;width:100%!important;min-width:0!important;
 padding-right:26px!important;overflow:hidden!important;text-overflow:ellipsis!important;
}
section.warehouse-document-filters .gns-gdf-lookup-clear{
 position:absolute!important;top:2px!important;right:2px!important;
 width:25px!important;min-height:27px!important;height:27px!important;
 padding:0!important;border:0!important;background:transparent!important;
 color:#6b7b8c!important;font-size:19px!important;cursor:pointer!important;
}
section.warehouse-document-filters .gns-gdf-lookup-clear[hidden]{
 display:none!important;
}
section.warehouse-document-filters .gns-gdf-lookup-results{
 position:absolute!important;left:0!important;top:calc(100% + 3px)!important;
 z-index:1600!important;
 width:min(410px,max(100%,240px))!important;
 max-width:min(410px,calc(100vw - 35px))!important;
 max-height:260px!important;overflow-y:auto!important;
 background:#fff!important;padding:4px!important;
 border:1px solid #94b1d2!important;border-radius:8px!important;
 box-shadow:0 12px 26px #1b3f602f!important;
}
section.warehouse-document-filters .gns-gdf-lookup-results[hidden]{display:none!important}
section.warehouse-document-filters .gns-gdf-lookup-option{
 display:block!important;width:100%!important;min-height:42px!important;
 padding:6px 9px!important;margin:0!important;border:0!important;
 border-radius:4px!important;background:#fff!important;
 color:#183c60!important;text-align:left!important;cursor:pointer!important;
}
section.warehouse-document-filters .gns-gdf-lookup-option strong,
section.warehouse-document-filters .gns-gdf-lookup-option small{
 display:block!important;white-space:normal!important;line-height:1.3!important;
}
section.warehouse-document-filters .gns-gdf-lookup-option strong{font-size:12px!important}
section.warehouse-document-filters .gns-gdf-lookup-option small{font-size:10px!important;color:#64788d!important}
section.warehouse-document-filters .gns-gdf-lookup-option:hover,
section.warehouse-document-filters .gns-gdf-lookup-option.active{
 background:#eaf3fc!important;
}
section.warehouse-document-filters .gns-gdf-lookup-notice{
 font-size:12px!important;padding:10px 8px!important;color:#63768b!important;
}
section.warehouse-document-filters .gns-gdf-chosen .gns-gdf-lookup-text{
 background:#eaf7ed!important;border-color:#5ba983!important;color:#235b40!important;
}
@media(max-width:700px){
 section.warehouse-document-filters .form-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
 section.warehouse-document-filters .gns-doc-filter-prefs{grid-template-columns:repeat(2,minmax(0,1fr))!important}
}

/* Keep active filter suggestions above subsequent document toolbar, below modal dialogs */
section.warehouse-document-filters{z-index:80!important;isolation:auto!important}
main.content:has(section.warehouse-document-filters) .warehouse-toolbar{position:relative;z-index:1!important}

/* v2.7.186: preserve hidden state even when the display:flex layout is enforced */
section.warehouse-document-filters .form-grid>label.gns-gdf-hidden,
section.warehouse-document-filters .form-grid>.gns-document-filter-partner.gns-gdf-hidden {
 display:none!important;pointer-events:none!important;
}

/* Open popup must rise above sibling grid cells even when those are later in DOM. */
section.warehouse-document-filters .form-grid>label:focus-within,
section.warehouse-document-filters .form-grid>.gns-document-filter-partner:focus-within {
 z-index:2500!important;
}

/* v2.7.186: user-specific filter layouts / no orange focus outline */
section.warehouse-document-filters .form-grid,
section.warehouse-document-filters .form-grid.gns-extra-open{
 display:grid!important;
 grid-template-columns:repeat(auto-fit,minmax(min(100%,190px),1fr))!important;
 grid-auto-flow:row!important;grid-auto-rows:auto!important;align-items:start!important;
 width:100%!important;max-width:100%!important;box-sizing:border-box!important;
 gap:12px!important;overflow:visible!important;max-height:none!important;
}
section.warehouse-document-filters .form-grid>label,
section.warehouse-document-filters .form-grid>.gns-document-filter-partner{
 display:flex!important;flex-direction:column!important;gap:3px!important;
 width:100%!important;max-width:100%!important;min-width:0!important;
 padding:0!important;margin:0!important;align-self:start!important;
 position:relative!important;box-sizing:border-box!important;
}
section.warehouse-document-filters .form-grid>label>span{
 display:block!important;position:static!important;transform:none!important;
 white-space:normal!important;overflow-wrap:anywhere!important;line-height:1.25!important;
 margin:0!important;padding:0!important;
}
section.warehouse-document-filters .form-grid input,
section.warehouse-document-filters .form-grid select{
 max-width:100%!important;min-width:0!important;box-sizing:border-box!important;
}
section.warehouse-document-filters .gns-gdf-active{
 outline:none!important;outline-offset:0!important;box-shadow:none!important;
}
@media(max-width:700px){
 section.warehouse-document-filters .form-grid,
 section.warehouse-document-filters .form-grid.gns-extra-open{
  grid-template-columns:repeat(auto-fit,minmax(min(100%,170px),1fr))!important;
 }
}
@media(max-width:420px){
 section.warehouse-document-filters .form-grid,
 section.warehouse-document-filters .form-grid.gns-extra-open{
  grid-template-columns:minmax(0,1fr)!important;
 }
}



/* DEV v2.7.187 — DOCUMENTS ONLY. GNS lock_state controls 2 colors.
   Unlocked: soft green; locked: soft orange. No blue alternate or selected rows. */
.gns-grid .gns-grid-table tbody tr.gns-document-unlocked>td,
.gns-grid .gns-grid-table tbody tr.gns-document-unlocked:not(.selected)>td{
 background:#E7F5EB!important;color:#194734!important;
 border-bottom:1px solid #D6ECDD!important;
 font-weight:550!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-locked>td,
.gns-grid .gns-grid-table tbody tr.gns-document-locked:not(.selected)>td{
 background:#FFF0E3!important;color:#71492C!important;
 border-bottom:1px solid #F2DAC5!important;
 font-weight:500!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-unlocked>td:first-child,
.gns-grid .gns-grid-table tbody tr.gns-document-unlocked:not(.selected)>td:first-child{
 border-left:4px solid #4C9E72!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-locked>td:first-child,
.gns-grid .gns-grid-table tbody tr.gns-document-locked:not(.selected)>td:first-child{
 border-left:4px solid #D59656!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-unlocked.selected>td,
.gns-grid .gns-grid-table tbody tr.gns-document-unlocked:hover>td{
 background:#D4EDD9!important;color:#153D2A!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-locked.selected>td,
.gns-grid .gns-grid-table tbody tr.gns-document-locked:hover>td{
 background:#FBE2CC!important;color:#59391F!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-unlocked :is(select,input,button),
.gns-grid .gns-grid-table tbody tr.gns-document-locked :is(select,input,button){
 color:inherit;
}


/* 2.7.188 — main readable nomenclature name, small secondary product code */
.invoice-compact-dialog table tbody tr td:nth-child(2) > strong{
 display:block!important;color:#173B53!important;
 font-size:12px!important;font-weight:760!important;line-height:1.35!important;
 white-space:normal!important;overflow-wrap:anywhere!important;
}
.invoice-compact-dialog table tbody tr td:nth-child(2) > small{
 display:block!important;color:#667B8C!important;
 font-size:10px!important;font-weight:400!important;line-height:1.3!important;
 margin-top:2px!important;
}


/* v2.7.189 GNS document completion: DONE (locked OR accounting-closed OR posted)=GREEN.
   All others=ORANGE. X8 delivery is not accounting close. Never blue.
*/
.gns-grid .gns-grid-table tbody tr.gns-document-finished>td,
.gns-grid .gns-grid-table tbody tr.gns-document-finished:not(.selected)>td{
 background:#E7F5EB!important;color:#194734!important;
 border-bottom:1px solid #D6ECDD!important;font-weight:550!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-incomplete>td,
.gns-grid .gns-grid-table tbody tr.gns-document-incomplete:not(.selected)>td{
 background:#FFF0E3!important;color:#71492C!important;
 border-bottom:1px solid #F2DAC5!important;font-weight:500!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-finished>td:first-child,
.gns-grid .gns-grid-table tbody tr.gns-document-finished:not(.selected)>td:first-child{
 border-left:4px solid #4C9E72!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-incomplete>td:first-child,
.gns-grid .gns-grid-table tbody tr.gns-document-incomplete:not(.selected)>td:first-child{
 border-left:4px solid #D59656!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-finished.selected>td,
.gns-grid .gns-grid-table tbody tr.gns-document-finished:hover>td{
 background:#D4EDD9!important;color:#153D2A!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-incomplete.selected>td,
.gns-grid .gns-grid-table tbody tr.gns-document-incomplete:hover>td{
 background:#FBE2CC!important;color:#59391F!important;
}
.gns-grid .gns-grid-table tbody tr.gns-document-finished :is(select,input,button),
.gns-grid .gns-grid-table tbody tr.gns-document-incomplete :is(select,input,button){
 color:inherit;
}


/* DEV 2.7.191 definitive document filter structure.
   Never clip the "Pielāgot" form: all checkboxes are visible, grid grows naturally.
   Prevent any partner search control from extending into neighboring cells.
*/
section.warehouse-document-filters {
 display:grid!important;
 grid-template-columns:minmax(0,1fr)!important;
 grid-auto-rows:max-content!important;
 align-content:start!important;
 align-items:stretch!important;
 height:auto!important;
 min-height:0!important;
 overflow:visible!important;
 box-sizing:border-box!important;
 position:relative!important;
}
section.warehouse-document-filters .gns-doc-filter-prefs:not([hidden]){
 display:grid!important;
 grid-template-columns:repeat(auto-fit,minmax(min(100%,155px),1fr))!important;
 grid-auto-flow:row!important;grid-auto-rows:max-content!important;
 align-content:start!important;align-items:start!important;
 width:100%!important;min-width:0!important;
 height:auto!important;min-height:0!important;max-height:none!important;
 padding:10px 4px 14px!important;margin:9px 0 13px!important;
 box-sizing:border-box!important;
 overflow:visible!important;overflow-x:visible!important;overflow-y:visible!important;
 gap:7px 12px!important;
 position:relative!important;
 clear:both!important;
 border-top:1px solid #e0e8f1!important;
 border-bottom:1px solid #cbd5df!important;
}
section.warehouse-document-filters .gns-doc-filter-prefs[hidden] {
 display:none!important;
}
section.warehouse-document-filters .gns-doc-filter-prefs:not([hidden]) .gns-pref-heading {
 display:block!important;grid-column:1 / -1!important;
 margin:1px 0 3px!important;min-height:16px!important;
 position:static!important;
}
section.warehouse-document-filters .gns-doc-filter-prefs:not([hidden]) label {
 display:flex!important;position:static!important;
 align-items:center!important;justify-content:flex-start!important;
 gap:5px!important;width:100%!important;min-width:0!important;
 height:auto!important;min-height:20px!important;
 white-space:normal!important;overflow:visible!important;overflow-wrap:anywhere!important;
 margin:0!important;padding:0!important;box-sizing:border-box!important;
}
section.warehouse-document-filters .gns-doc-filter-prefs:not([hidden]) label>span{
 display:inline!important;min-width:0!important;
 font-size:11px!important;line-height:1.3!important;
}
section.warehouse-document-filters .gns-doc-filter-prefs:not([hidden]) label>input[type=checkbox]{
 position:static!important;display:inline-block!important;
 width:15px!important;min-width:15px!important;max-width:15px!important;
 height:15px!important;min-height:15px!important;max-height:15px!important;
 margin:0!important;padding:0!important;flex:0 0 15px!important;
}
section.warehouse-document-filters .gns-doc-filter-prefs:not([hidden]) button[data-gdf-reset]{
 justify-self:start!important;align-self:center!important;
 position:static!important;min-height:30px!important;
}
section.warehouse-document-filters .form-grid,
section.warehouse-document-filters .form-grid.gns-extra-open{
 display:grid!important;grid-auto-flow:row!important;grid-auto-rows:max-content!important;
 grid-template-columns:repeat(auto-fit,minmax(min(100%,180px),1fr))!important;
 align-items:start!important;align-content:start!important;
 column-gap:12px!important;row-gap:12px!important;
 width:100%!important;max-width:100%!important;min-width:0!important;
 height:auto!important;min-height:0!important;max-height:none!important;
 margin:0!important;padding:0!important;
 overflow:visible!important;box-sizing:border-box!important;
 position:relative!important;
}
section.warehouse-document-filters .form-grid>label,
section.warehouse-document-filters .form-grid>.gns-document-filter-partner{
 width:100%!important;max-width:100%!important;min-width:0!important;
 min-height:0!important;
 box-sizing:border-box!important;
 position:relative!important;
 margin:0!important;padding:0!important;overflow:visible!important;
}
section.warehouse-document-filters .form-grid>.gns-document-filter-partner,
section.warehouse-document-filters .gns-document-filter-partner .gns-shared-partner-picker,
section.warehouse-document-filters .gns-document-filter-partner .gns-shared-partner-entry{
 display:flex!important;flex-direction:column!important;
 width:100%!important;max-width:100%!important;min-width:0!important;
 flex:1 1 auto!important;
 box-sizing:border-box!important;overflow:visible!important;
}
section.warehouse-document-filters .gns-document-filter-partner .gns-shared-partner-entry{
 display:flex!important;flex-direction:row!important;
 align-items:center!important;position:relative!important;
 width:100%!important;max-width:100%!important;min-width:0!important;
 flex:0 0 32px!important;
}
section.warehouse-document-filters .gns-document-filter-partner .gns-shared-partner-entry input{
 display:block!important;
 width:100%!important;max-width:100%!important;min-width:0!important;
 flex:1 1 0!important;
 box-sizing:border-box!important;
 padding-right:66px!important;
}
section.warehouse-document-filters .gns-document-filter-partner .gns-shared-partner-entry button{
 max-width:30px!important;flex:0 0 auto!important;
}
section.warehouse-document-filters .gns-document-filter-partner .gns-shared-partner-quick{
 left:0!important;right:auto!important;
 max-width:min(380px,calc(100vw - 40px))!important;
}
main.content:has(section.warehouse-document-filters) .warehouse-toolbar{
 position:relative!important;z-index:1!important;
 margin-top:8px!important;clear:both!important;
}
@media(max-width:700px){
 section.warehouse-document-filters .gns-doc-filter-prefs:not([hidden]){
   grid-template-columns:repeat(auto-fit,minmax(min(100%,145px),1fr))!important;
 }
 section.warehouse-document-filters .form-grid,
 section.warehouse-document-filters .form-grid.gns-extra-open{
   grid-template-columns:repeat(auto-fit,minmax(min(100%,170px),1fr))!important;
 }
}
@media(max-width:420px){
 section.warehouse-document-filters .form-grid,
 section.warehouse-document-filters .form-grid.gns-extra-open{
   grid-template-columns:minmax(0,1fr)!important;
 }
}


/* v2.7.192: the embedded GNS partner picker has a real 220px minimum.
   Allocate enough grid track space instead of allowing it to spill into Līgums. */
section.warehouse-document-filters .form-grid>.gns-document-filter-partner{
 grid-column:span 2!important;min-width:0!important;max-width:100%!important;
 width:100%!important;box-sizing:border-box!important;align-self:start!important;
}
@media(max-width:420px){
 section.warehouse-document-filters .form-grid>.gns-document-filter-partner{
   grid-column:1/-1!important;
 }
}
