/* Minor ArduConfigurator brand tweaks on top of the Read-the-Docs theme.
   Keep this light — the goal is to match the ArduPilot wiki's familiar look. */
.wy-side-nav-search { background-color: #1f2a37; }
.wy-nav-top { background-color: #1f2a37; }

/* --- Parameter search ---------------------------------------------------
   Client-side filter over a prebuilt name index. Sized for a phone first:
   the upstream single-page parameter list is what this replaces. */
.param-search input[type='search'] {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 14px;
  font-size: 16px; /* >=16px stops iOS Safari zooming the page on focus */
  border-radius: 8px;
  border: 1px solid var(--color-background-border, #ccc);
  background: var(--color-background-primary, #fff);
  color: var(--color-foreground-primary, #111);
}

.param-search__status {
  margin: 8px 0 4px;
  font-size: 0.9em;
  color: var(--color-foreground-secondary, #666);
}

.param-search__results {
  list-style: none;
  margin: 0;
  padding: 0;
}

.param-search__results li {
  padding: 8px 0;
  border-bottom: 1px solid var(--color-background-border, #eee);
}

.param-search__results a {
  font-family: var(--font-stack--monospace, monospace);
  font-weight: 600;
}

.param-search__meta {
  display: block;
  font-size: 0.85em;
  color: var(--color-foreground-secondary, #666);
}

/* Search stays put while results scroll — it is on every parameter page, so it
   should behave like a persistent tool rather than page content. */
.param-search--sticky {
  position: sticky;
  top: 0;
  z-index: 5;
  padding: 8px 0;
  background: var(--color-background-primary, #fff);
}

.param-search__desc {
  display: block;
  margin-top: 2px;
  font-size: 0.85em;
  line-height: 1.45;
  color: var(--color-foreground-primary, #222);
}

/* Empty until a query is typed, so it must not reserve vertical space above
   the page's real content. */
.param-search__status:empty {
  display: none;
  margin: 0;
}

/* :param:`NAME` — a literal that links into the generated parameter reference
   (the role lives in conf.py). Furo renders a bare literal as plain code, so
   without this a linked parameter is indistinguishable from an unlinked one. */
a.param-ref,
a.param-ref:visited {
  text-decoration: none;
  border-bottom: 1px dotted var(--color-brand-content, #0a7);
}

a.param-ref code,
a.param-ref:visited code {
  color: var(--color-brand-content, #0a7);
}

a.param-ref:hover {
  border-bottom-style: solid;
}
