/* ==========================================================================================================
   home-search.css: the home search results (the suggestion list that search-suggest.js adds inside the search row).
   The script's own classes are not known here, so every rule targets what is inside .hs-inner by position and
   element type: anything that is not the input (.hs-input) or the button (.hs-btn) is the results. The input and
   button keep their widths; the results get their own full-width panel below the row.
   ========================================================================================================== */

/* the row wraps, so results can take a full line beneath the input and button */
.hx .hs-inner { flex-wrap: wrap; row-gap: 0; }

/* the input keeps a real width (it was being squeezed to a few pixels by the results) */
.hx .hs-inner > .hs-input { flex: 1 1 260px; min-width: 0; }
.hx .hs-inner > .hs-btn { flex: none; }

/* focus: one gold ring around the whole search row, not a box around the narrow input */
.hx .hs-input:focus-visible,
.hx .hs-input:focus { outline: none; }
.hx .hs-inner:focus-within { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 18px; }

/* the results panel: one full-width block under the row */
.hx .hs-inner > :not(.hs-input):not(.hs-btn):not(a) {
  order: 10; flex: 1 1 100%; width: 100%; min-width: 0;
  display: flex; flex-direction: column; gap: 2px;
  margin-top: 8px; padding: 6px; max-height: 360px; overflow-y: auto;
  border-top: 1px solid var(--rule); background: var(--ivory);
  border-radius: 14px;
}
/* links placed directly in the row (if the script does not wrap them) get the same full-width treatment */
.hx .hs-inner > a { order: 10; flex: 1 1 100%; width: 100%; }

/* each result is its own row: one line, clear type and name, no underline */
.hx .hs-inner a {
  display: flex; align-items: center; gap: 10px; min-width: 0;
  padding: 10px 14px; border-radius: 10px;
  color: var(--ink); text-decoration: none;
  font: 500 15px/1.35 var(--sans);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  transition: background .15s;
}
.hx .hs-inner a:hover, .hx .hs-inner a:focus-visible { background: rgba(201,162,39,.12); outline: none; }
.hx .hs-inner a:focus-visible { box-shadow: inset 0 0 0 2px var(--gold); }
.hx .hs-inner a strong { font-weight: 700; }

/* the small type label on each result (Tool, News, Compare...) */
.hx .hs-inner a .sg-type {
  flex: none; font: 600 10.5px/1 var(--mono); letter-spacing: .12em; text-transform: uppercase;
  color: var(--accent); background: rgba(200,64,26,.08); padding: 4px 8px; border-radius: 999px;
}

/* "See all results" sits at the bottom of the panel */
.hx .hs-inner a.sg-all, .hx .hs-inner a[href*="search"] {
  justify-content: center; margin-top: 4px; border-top: 1px solid var(--rule); border-radius: 0 0 10px 10px;
  color: var(--accent); font-weight: 600;
}


/* ---- one look for every result, whatever type it is ----------------------------------------------------------
   The script styles each result type (tool, news, prompt, comparison) its own way, so the fonts differed.
   Every element inside a result now takes the same family, size, line height and case. Only the matched words
   (strong / b) are bolder. Colour and layout are not touched, so the rows stay as they are. */
.hx .hs-inner > :not(.hs-input):not(.hs-btn) *,
.hx .hs-inner > a * {
  font-family: var(--sans) !important;
  font-size: 15px !important;
  line-height: 1.35 !important;
  font-style: normal !important;
  letter-spacing: normal !important;
  text-transform: none !important;
  font-weight: 500 !important;
}
.hx .hs-inner > :not(.hs-input):not(.hs-btn) strong,
.hx .hs-inner > :not(.hs-input):not(.hs-btn) b,
.hx .hs-inner > a strong,
.hx .hs-inner > a b { font-weight: 700 !important; }
.hx .hs-inner a, .hx .hs-inner a * { color: var(--ink); }
.hx .hs-inner a.sg-all, .hx .hs-inner a.sg-all * { color: var(--accent); }

/* phones: the button drops under the input to keep both tappable */
@media (max-width: 560px) {
  .hx .hs-inner > .hs-input { flex: 1 1 100%; }
  .hx .hs-inner > .hs-btn { flex: 1 1 100%; width: 100%; }
  .hx .hs-inner a { white-space: normal; }
}
@media (prefers-reduced-motion: reduce) { .hx .hs-inner a { transition: none; } }
