/* Product search shares the site's colours and typography. */
.header-search { display:inline-flex; align-items:center; justify-content:center; gap:7px; min-width:40px; min-height:44px; font-size:13px; font-weight:500; }
.header-search svg { width:19px; height:19px; flex-shrink:0; }
.header-search:hover { color:var(--accent-text); }
.search-home-slot { margin-top:28px; max-width:520px; min-height:86px; }
.product-search { position:relative; text-align:left; }
.product-search[hidden], .search-panel[hidden], .search-examples[hidden] { display:none; }
.search-home > label { display:block; font-size:14px; font-weight:600; margin-bottom:10px; }
.search-field { display:flex; background:var(--surface); border:1px solid var(--border-35); border-radius:var(--r-opt); overflow:hidden; }
.search-field:focus-within { outline:2px solid var(--accent-text); outline-offset:2px; }
.search-field input { width:100%; min-width:0; border:0; outline:0; background:transparent; color:var(--ink); padding:14px 16px; font:400 16px/1.4 var(--font); }
.search-field input::placeholder { color:var(--muted); opacity:1; }
.search-field button { flex-shrink:0; width:48px; border:0; border-left:1px solid var(--border); color:var(--ink); background:var(--tint); font-size:22px; }
.search-field button:hover { background:var(--tint-2); }
.search-panel { padding:16px 0 0; }
.search-home .search-panel { position:absolute; top:100%; left:0; right:0; z-index:30; margin-top:8px; background:var(--surface); border:1px solid var(--border-25); border-radius:var(--r-card); padding:16px; max-height:min(560px,65vh); max-height:min(560px,65dvh); overflow:auto; overscroll-behavior:contain; }
.search-home .search-panel--above { top:auto; bottom:100%; margin-top:0; margin-bottom:8px; }
.search-status { font-size:13px; line-height:1.5; color:var(--muted); margin:0 0 12px; }
.search-examples { display:flex; flex-wrap:wrap; gap:8px; margin-bottom:16px; }
.search-examples button { border:1px solid var(--border); border-radius:var(--r-btn); background:var(--tint); color:var(--ink); padding:10px 14px; min-height:44px; font-size:14px; }
.search-results { list-style:none; margin:0; padding:0; }
.search-results li + li { border-top:1px solid var(--border); }
.search-result { display:flex; align-items:center; gap:14px; padding:14px 4px; border-radius:var(--r-btn); color:var(--ink); }
.search-result:hover, .search-result:focus-visible { background:var(--tint); }
.search-result img, .search-result__symbol { width:56px; height:56px; flex-shrink:0; object-fit:contain; filter:grayscale(1); }
.search-result__symbol { display:grid; place-items:center; background:var(--tint-2); font-size:22px; }
.search-result__copy { min-width:0; }
.search-result strong { display:block; font-size:15px; line-height:1.4; font-weight:600; overflow-wrap:anywhere; }
.search-result__description { display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:2; overflow:hidden; font-size:12px; line-height:1.5; color:var(--muted); margin-top:4px; }
.search-footer { display:flex; justify-content:space-between; flex-wrap:wrap; gap:8px 20px; border-top:1px solid var(--border); margin-top:12px; padding-top:12px; font-size:13px; line-height:1.5; color:var(--accent-text); }
.search-footer a { padding:6px 0; text-decoration:underline; text-underline-offset:3px; }
.search-dialog { position:fixed; inset:64px 16px auto; margin:0 auto; width:min(680px,calc(100% - 32px)); max-width:none; max-height:calc(100vh - 96px); max-height:calc(100dvh - 96px); padding:28px; background:var(--surface); color:var(--ink); border:1px solid var(--border); border-radius:var(--r-card); overflow:auto; overscroll-behavior:contain; }
.search-dialog[open] { display:flex; flex-direction:column; }
.search-dialog__head { flex-shrink:0; }
.search-dialog .product-search { display:flex; flex-direction:column; min-height:0; }
.search-dialog .search-field { flex-shrink:0; }
.search-dialog .search-panel { overflow:auto; min-height:0; overscroll-behavior:contain; }
.search-dialog::backdrop { background:rgba(15,42,31,.65); }
.search-dialog__head { display:flex; align-items:center; justify-content:space-between; gap:16px; margin-bottom:20px; }
.search-dialog__head h2 { font-size:24px; line-height:1.2; margin:0; }
.search-close { width:44px; height:44px; flex-shrink:0; border:1px solid var(--border); border-radius:var(--r-btn); background:var(--surface); color:var(--ink); font-size:28px; line-height:1; }
body.search-open { overflow:hidden; padding-right:var(--search-scrollbar,0px); }
.product-section :is(h3,h4)[id] { scroll-margin-top:100px; }
@media(min-width:1201px) { .header-search span { display:none; } .header__actions { gap:12px; } .header__in { gap:16px; } }
@media(max-width:640px) { .header-search span { display:none; } .search-dialog { inset:12px 12px auto; width:calc(100% - 24px); max-height:calc(100vh - 24px); max-height:calc(100dvh - 24px); padding:18px; } .search-dialog__head h2 { font-size:20px; } .search-home .search-panel { padding:12px; } .search-result { gap:10px; } }
@media(min-width:421px) and (max-width:540px) { .header__actions > .btn { display:none; } }
