/* stylelint-disable selector-class-pattern */

/* =========================================================
   JSC COMPONENT CONTRACT
   File: jsc-idx-searchbar-init.css
   Layer: IDX / Compact Searchbar / First Paint Stability
   Version: 1.1

   PURPOSE
   ----------------------------------------------------------------
   Prevents FlexMLS compact widget FOUC and keeps the advanced
   search panel closed only during first paint.

   IMPORTANT
   ----------------------------------------------------------------
   Does NOT hide the fixed shell or header.
   Does NOT replace button text with pseudo-elements.
========================================================= */


/* =========================================================
   1) FORCE ADVANCED PANEL CLOSED ONLY DURING INIT
========================================================= */

html.jsc-ui-init:not(.jsc-idx-widget-ready) .jsc-idx-search-panel{
  display: none !important;
}

/* =========================================================
   3) REVEAL COMPACT WIDGET AFTER INIT
========================================================= */

html.jsc-idx-widget-ready
.jsc-idx-searchbar .flexmls_connect__search_new form{
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity 140ms ease;
}

/* =========================================================
   2) HIDE RAW COMPACT FLEXMLS FORM UNTIL READY
========================================================= */

html.jsc-ui-init:not(.jsc-idx-widget-ready)
.jsc-idx-searchbar .flexmls_connect__search_new form{
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}