/* IM Global Search v1.3 — minimal desktop + mobile expand-in-header */

.im-gs-root[hidden]{display:none!important}
.im-gs-root:not([hidden]){display:contents}

/* ===== Desktop ===== */
.im-gs-desktop{
  display:none;
  position:relative;
  flex:0 0 auto;
  width:220px;
  max-width:28vw;
  margin:0 0 0 12px;
  z-index:10050;
}
@media(min-width:992px){
  .im-gs-desktop{display:block}
}
@media(min-width:1200px){
  .im-gs-desktop{width:260px}
}
.im-gs-desktop--fixed{
  display:block;
  position:fixed;
  top:16px;
  right:24px;
  width:min(280px,40vw);
  z-index:10050;
}

.im-gs-form{
  display:flex;
  align-items:center;
  background:rgba(255,255,255,.92);
  border:none;
  border-radius:6px;
  height:36px;
  overflow:hidden;
  transition:background .15s ease, box-shadow .15s ease;
}
.im-gs-form:focus-within{
  background:#fff;
  box-shadow:0 0 0 2px rgba(0,0,0,.12);
}
.im-gs-icon{
  display:flex;
  align-items:center;
  justify-content:center;
  width:36px;
  flex:0 0 36px;
  color:#555;
  pointer-events:none;
}
.im-gs-input{
  flex:1 1 auto;
  border:0;
  background:transparent;
  padding:0 8px 0 0;
  height:100%;
  font-size:13px;
  font-family:inherit;
  color:#111;
  outline:none;
  min-width:0;
}
.im-gs-input::placeholder{color:#888}
.im-gs-submit{
  flex:0 0 auto;
  border:0;
  background:transparent;
  color:#333;
  width:36px;
  height:100%;
  padding:0;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:0;
}
.im-gs-submit::after{
  content:"";
  display:block;
  width:14px;
  height:14px;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='none' stroke='%23333' stroke-width='2'%3E%3Cpath d='M5 1l6 6-6 6'/%3E%3C/svg%3E") center/contain no-repeat;
  opacity:.7;
}
.im-gs-submit:hover::after{opacity:1}

/* Desktop dropdown */
.im-gs-suggest{
  position:absolute;
  right:0;
  left:auto;
  top:calc(100% + 6px);
  width:min(360px,92vw);
  background:#fff;
  border-radius:8px;
  border:1px solid #e8e8e8;
  box-shadow:0 8px 30px rgba(0,0,0,.12);
  max-height:min(70vh,420px);
  overflow-y:auto;
  z-index:10060;
  text-align:left;
}
.im-gs-suggest[hidden]{display:none!important}
.im-gs-group-title{
  margin:0;padding:8px 12px 4px;
  font-size:10px;font-weight:600;letter-spacing:.05em;
  text-transform:uppercase;color:#999;
}
.im-gs-item{
  display:block;padding:8px 12px;text-decoration:none;color:#1a1a1a;
}
.im-gs-item:hover,.im-gs-item:focus{background:#f5f5f5;outline:none}
.im-gs-item-title{display:block;font-size:13.5px;font-weight:500;line-height:1.35}
.im-gs-item-meta{display:block;font-size:11.5px;color:#888;margin-top:1px}
.im-gs-note{padding:6px 12px;font-size:11px;color:#999;border-top:1px solid #f0f0f0}
.im-gs-footer{
  display:block;padding:10px 12px;font-size:12.5px;font-weight:600;
  color:#111;text-decoration:none;border-top:1px solid #eee;background:#fafafa;
  border-radius:0 0 8px 8px;
}
.im-gs-footer:hover{background:#f0f0f0}
.im-gs-empty,.im-gs-loading{padding:14px 12px;font-size:13px;color:#888}

/* ===== Mobile: icon only ===== */
.im-gs-mobile-trigger{
  display:none;
  width:40px;height:40px;
  border:0;border-radius:6px;
  background:transparent;
  color:#111;
  align-items:center;justify-content:center;
  cursor:pointer;z-index:10040;
  padding:0;
}
.im-gs-mobile-trigger--placed{
  position:absolute;
  top:50%;
  right:48px;
  transform:translateY(-50%);
}
@media(max-width:991.98px){
  .im-gs-mobile-trigger{display:flex}
  .im-gs-desktop{display:none!important}
}

/* Expand bar: replaces header content area */
.im-gs-mobile-expand{
  display:none;
  position:fixed;
  top:0;left:0;right:0;
  z-index:10070;
  background:#fac11c;
  padding:10px 12px;
  padding-top:max(10px, env(safe-area-inset-top));
  box-shadow:0 2px 8px rgba(0,0,0,.08);
}
.im-gs-mobile-expand:not([hidden]){
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:8px;
}
.im-gs-mobile-back{
  flex:0 0 auto;
  width:36px;height:36px;
  border:0;border-radius:6px;
  background:transparent;
  color:#111;
  display:flex;align-items:center;justify-content:center;
  cursor:pointer;padding:0;
}
.im-gs-form--mobile{
  flex:1 1 auto;
  min-width:0;
  height:40px;
  background:#fff;
  border-radius:8px;
  box-shadow:none;
}
.im-gs-form--mobile .im-gs-input{
  padding-left:12px;
  font-size:15px;
}
.im-gs-suggest--mobile{
  flex:1 1 100%;
  position:relative;
  top:0;left:0;right:0;
  width:100%;
  max-height:min(60vh,400px);
  margin-top:4px;
  border-radius:8px;
  box-shadow:0 8px 24px rgba(0,0,0,.12);
}

/* Dim page slightly when expand open */
body.im-gs-expand-open::after{
  content:"";
  position:fixed;
  inset:0;
  background:rgba(0,0,0,.25);
  z-index:10065;
  pointer-events:none;
}
body.im-gs-expand-open{overflow:hidden}

/* ===== Results page ===== */
.im-gs-results{max-width:960px;margin:0 auto;padding:32px 16px 64px}
.im-gs-results h1{font-size:1.5rem;font-weight:600;margin:0 0 6px;color:#111}
.im-gs-results-meta{color:#888;font-size:13px;margin-bottom:12px}
.im-gs-results-hint{
  font-size:13px;color:#666;margin-bottom:20px;
  padding:10px 12px;background:#f7f7f7;border-radius:6px;
}
.im-gs-tabs{
  display:flex;flex-wrap:wrap;gap:0;
  border-bottom:1px solid #e5e5e5;margin-bottom:20px;
}
.im-gs-tab{
  appearance:none;border:0;background:transparent;
  padding:10px 14px;font-size:13px;font-weight:500;
  color:#666;cursor:pointer;font-family:inherit;
  border-bottom:2px solid transparent;margin-bottom:-1px;
  text-decoration:none;
}
.im-gs-tab:hover{color:#111}
.im-gs-tab.is-active{color:#111;border-bottom-color:#111}
.im-gs-tab-count{margin-left:4px;font-size:11px;color:#999;font-weight:400}
.im-gs-panel[hidden]{display:none!important}
.im-gs-card{
  display:block;padding:12px 0;
  border-bottom:1px solid #f0f0f0;
  text-decoration:none;color:inherit;
}
.im-gs-card:hover .im-gs-card-title{color:#000}
.im-gs-card-title{font-size:15px;font-weight:500;margin:0 0 2px;color:#111}
.im-gs-card-excerpt{font-size:13px;color:#666;line-height:1.4;margin:0}
.im-gs-card-type{
  font-size:10px;text-transform:uppercase;letter-spacing:.06em;
  color:#999;font-weight:600;margin:18px 0 6px;
}
.im-gs-slow-note{font-size:12px;color:#999;margin-top:10px}
.screen-reader-text{
  border:0;clip:rect(1px,1px,1px,1px);clip-path:inset(50%);
  height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;
}

#header .navbar-wrapper.im-gs-host-flex,
#header-ext .navbar-wrapper.im-gs-host-flex,
.navbar-wrapper.im-gs-host-flex{
  display:flex!important;
  flex-wrap:nowrap;
  align-items:center;
  width:100%;
}
#header .navbar-wrapper.im-gs-host-flex .navigation-container,
#header-ext .navbar-wrapper.im-gs-host-flex .navigation-container{
  margin-left:auto;
}
