/* The search bar shared by Prices, Specialists and DPC clinics. See assets/js/searchbar.js.
   .sb is the large one for a first screen; .sb--compact is the same tool over a list of results. */
.sb{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(0,1fr) auto;background:var(--sheet);border-radius:var(--r);box-shadow:0 2px 0 rgba(10,42,33,.55)}
.sb-cell{position:relative;min-width:0;padding:13px 20px 9px;cursor:text}
.sb-cell+.sb-cell{border-left:1px solid var(--rule-2)}
.sb-cell:focus-within{box-shadow:inset 0 0 0 2px var(--ink),inset 0 0 0 6px var(--mark);z-index:2}
.sb-cell label{display:block;font-size:14px;font-weight:600;line-height:1.3;color:var(--ink-2);cursor:text}
.sb-cell input{display:block;width:100%;min-width:0;min-height:40px;margin:0;padding:0;border:0;border-radius:0;background:none;box-shadow:none;color:var(--ink);font:500 clamp(21px,2.1vw,27px)/1.25 var(--text);text-overflow:ellipsis}
.sb-cell input:focus,.sb-cell input:focus-visible{outline:0;box-shadow:none;border:0}
.sb-cell input::placeholder{color:var(--ink-3);font-weight:400;opacity:1}
.sb-cell.sb-bad label{color:var(--hosp)}
.sb-cell.sb-bad:focus-within{box-shadow:inset 0 0 0 2px var(--hosp)}

.sb-go{min-width:164px;padding:0 34px 3px;border:0;border-radius:0 var(--r) var(--r) 0;background:var(--mark);color:var(--ink);font:700 21px var(--text);cursor:pointer;box-shadow:inset 0 -3px 0 var(--mark-edge);transition:background-color .12s}
@media (hover:hover){.sb-go:hover{background:#f9ef8e}}
.sb-go:active{box-shadow:none}
.sb-go:focus-visible{outline:2px solid var(--ink);outline-offset:-5px;box-shadow:none}

/* suggestions, hung under the field they belong to */
.sb-pop{position:absolute;z-index:30;top:100%;left:0;right:0;max-height:min(376px,52vh);overflow-y:auto;margin:0;padding:0;list-style:none;border-radius:0 0 var(--r) var(--r);background:#fff;box-shadow:0 0 0 1px var(--rule-2),0 3px 5px -2px rgba(15,43,36,.28);cursor:default}
.sb-pop li[role=option]{display:flex;justify-content:space-between;align-items:baseline;gap:14px;min-height:44px;padding:10px 20px;border-top:1px solid var(--rule);font-size:17px;font-weight:500;line-height:1.3;color:var(--ink);cursor:pointer}
.sb-pop li[role=option]:hover{background:var(--paper-2)}
.sb-pop li[aria-selected=true]{background:var(--paper-3)}
.sb-pop small{flex:none;max-width:45%;font-size:14px;font-weight:400;color:var(--ink-3);text-align:right}
.sb-g{padding:12px 20px 4px;font-size:14px;font-weight:600;color:var(--ink-3)}
.sb-none{padding:12px 20px;font-size:16px;color:var(--ink-2)}

/* the same tool, smaller */
.sb--compact .sb-cell{padding:7px 16px 3px}
.sb--compact .sb-cell label{font-size:13px}
.sb--compact .sb-cell input{min-height:30px;font-size:18px}
.sb--compact .sb-go{min-width:116px;padding:0 22px;font-size:17px}
.sb--compact .sb-pop li[role=option]{padding-left:16px;padding-right:16px}

@media (max-width:760px){
  .sb{grid-template-columns:minmax(0,1fr)}
  .sb-cell{padding:11px 14px 7px}
  .sb-cell+.sb-cell{border-left:0;border-top:1px solid var(--rule-2)}
  .sb-cell input{min-height:36px;font-size:22px}
  .sb-go{min-height:56px;min-width:0;padding:0 20px;border-radius:0 0 var(--r) var(--r);font-size:19px}
  /* stacked: a list pushes what is under it down instead of covering it, so Where and Search stay reachable */
  .sb-pop{position:static;max-height:232px;margin:8px -14px -7px;box-shadow:none;border-radius:0}

  .sb--compact{grid-template-columns:minmax(0,1fr) auto}
  .sb--compact .sb-what{grid-column:1/-1}
  .sb--compact .sb-cell{padding:6px 13px 2px}
  .sb--compact .sb-cell input{min-height:28px;font-size:17px}
  /* compact: Where shares a row with Search, so its list hangs below the bar, under both */
  .sb--compact .sb-where .sb-pop{position:absolute;top:100%;left:0;right:-88px;max-height:min(300px,42vh);margin:0;box-shadow:0 0 0 1px var(--rule-2),0 3px 5px -2px rgba(15,43,36,.28)}
  .sb--compact .sb-go{min-height:50px;min-width:88px;padding:0 14px;font-size:16px;border-radius:0 0 var(--r) 0}
}
@media (prefers-reduced-motion:reduce){.sb-go{transition:none}}
