/* GANCANG Customer Marketplace v51.2 — mobile search + brand hotfix.
   Scope: Customer v51 only. Keeps the 8px system and uses the canonical GANCANG icon asset. */

/* Restore the canonical GANCANG mark used by the app/PWA. */
.g51-brand-mark{
  width:40px!important;
  height:40px!important;
  min-width:40px!important;
  flex:0 0 40px!important;
  padding:0!important;
  border-radius:50%!important;
  font-size:0!important;
  color:transparent!important;
  background-color:transparent!important;
  background-image:url('/icons/gancang-icon.svg?v=37')!important;
  background-repeat:no-repeat!important;
  background-position:center!important;
  background-size:contain!important;
  box-shadow:none!important;
  overflow:hidden!important;
}
.g51-brand{
  gap:8px!important;
  align-items:center!important;
}

/* Search must remain a single horizontal row on Android/Chrome.
   Flex is intentional here: it prevents legacy/global form-grid rules from
   shrinking the input to a few characters. */
.g51-search{
  position:relative!important;
  display:flex!important;
  flex-direction:row!important;
  align-items:center!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  height:56px!important;
  min-height:56px!important;
  margin:8px 0 16px!important;
  padding:0 8px 0 16px!important;
  gap:10px!important;
  overflow:hidden!important;
  white-space:nowrap!important;
}
.g51-search .sr-only{
  position:absolute!important;
  width:1px!important;
  height:1px!important;
  padding:0!important;
  margin:-1px!important;
  overflow:hidden!important;
  clip:rect(0,0,0,0)!important;
  white-space:nowrap!important;
  border:0!important;
  pointer-events:none!important;
}
.g51-search>svg{
  position:static!important;
  display:block!important;
  flex:0 0 22px!important;
  width:22px!important;
  height:22px!important;
  margin:0!important;
  align-self:center!important;
}
#g51-query{
  position:static!important;
  display:block!important;
  flex:1 1 0!important;
  width:auto!important;
  min-width:0!important;
  max-width:100%!important;
  height:48px!important;
  min-height:48px!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  outline:0!important;
  background:transparent!important;
  color:#171b46!important;
  font-size:16px!important;
  font-style:normal!important;
  font-weight:500!important;
  line-height:48px!important;
  letter-spacing:normal!important;
  text-align:left!important;
  text-indent:0!important;
  text-transform:none!important;
  writing-mode:horizontal-tb!important;
  text-orientation:mixed!important;
  white-space:nowrap!important;
  word-break:keep-all!important;
  overflow-wrap:normal!important;
  hyphens:none!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  transform:none!important;
  appearance:none!important;
  -webkit-appearance:none!important;
}
#g51-query::placeholder{
  color:#858da0!important;
  opacity:1!important;
  white-space:nowrap!important;
  word-break:keep-all!important;
  overflow-wrap:normal!important;
}
.g51-search .g51-chat-shortcut{
  position:static!important;
  display:flex!important;
  flex:0 0 44px!important;
  width:44px!important;
  min-width:44px!important;
  max-width:44px!important;
  height:44px!important;
  min-height:44px!important;
  margin:0!important;
  padding:0!important;
  align-items:center!important;
  justify-content:center!important;
  align-self:center!important;
  overflow:hidden!important;
  white-space:nowrap!important;
}
.g51-search .g51-chat-shortcut span{display:none!important}

@media (max-width:360px){
  .g51-brand-mark{
    width:38px!important;
    height:38px!important;
    min-width:38px!important;
    flex-basis:38px!important;
  }
  .g51-search{
    height:54px!important;
    min-height:54px!important;
    padding-left:12px!important;
    gap:8px!important;
  }
  #g51-query{
    height:46px!important;
    min-height:46px!important;
    line-height:46px!important;
    font-size:15px!important;
  }
  .g51-search .g51-chat-shortcut{
    flex-basis:42px!important;
    width:42px!important;
    min-width:42px!important;
    max-width:42px!important;
    height:42px!important;
    min-height:42px!important;
  }
}

@media (min-width:600px){
  .g51-search .g51-chat-shortcut{
    flex:0 0 auto!important;
    width:auto!important;
    min-width:96px!important;
    max-width:none!important;
    padding:0 14px!important;
    gap:6px!important;
  }
  .g51-search .g51-chat-shortcut span{display:inline!important}
}
