/* Rescue Listings: Find a pet filters (near me, breed, good with, sort, saved search) and the
   "Report this listing" form on the pet page. Loaded after /rl/shell.css by /pets/ and /pet/.
   Nothing new to look at: every value here is one shell.css (or content.css, for the breed
   suggestions) already uses. */

/* A message under a field: the size of .rl-hint, in the danger color the inputs already use. */
.rl-f-msg { font-size: .76rem; line-height: 1.5; color: var(--danger); }
.rl-filters__search .rl-f-msg { grid-column: 1 / -1; margin-top: -4px; }

/* Good with: a row of plain checkboxes under the same bold label as the other filters. */
.rl-f-good { margin: 0; padding: 0; border: 0; min-width: 0; }
.rl-f-good legend { padding: 0; margin-bottom: 7px; }
.rl-f-checks { display: flex; flex-wrap: wrap; gap: 0 20px; }
.rl-f-check {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  font-size: .84rem;
  font-weight: 700;
  color: var(--forest);
  cursor: pointer;
}
.rl-f-check input { width: 18px; height: 18px; margin: 0; accent-color: var(--forest); cursor: pointer; }

/* A message under one field must not push the next field's box down. */
.rl-filters .rl-field { align-content: start; }

/* The disclosure: "More filters" / "Fewer filters" (aria-expanded says which). Closed, the first
   row of filters shows and the results stay on the first screen, at every width. */
.rl-filters__toggle { display: flex; align-items: end; }
.rl-filters__toggle .rl-btn { flex: 1; }
.rl-filters.is-compact [data-more] { display: none; }

@media (min-width: 701px) {
  .rl-f-good { grid-column: span 3; }
}

@media (max-width: 700px) {
  .rl-f-good,
  .rl-f-wide { grid-column: 1 / -1; }
  .rl-filters__toggle { grid-column: 1 / -1; }
}

/* The narrowest phones: ZIP and distance get a row each, so "250 miles" is not cut off. */
@media (max-width: 360px) {
  .rl-f-near { grid-column: 1 / -1; }
}

/* Breed suggestions: the directory's type-ahead list (content.css .rl-search__list), same values. */
.rl-search__box { position: relative; min-width: 0; }
.rl-search__box .rl-input { width: 100%; max-width: 100%; }
.rl-search__list {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  z-index: 30;
  width: 100%;
  max-width: 100%;
  max-height: min(60vh, 420px);
  overflow-x: hidden;
  overflow-y: auto;
  margin: 0;
  padding: 4px;
  list-style: none;
  background: #fff;
  border: 1px solid #bdcdca;
  border-radius: 8px;
  box-shadow: var(--shadow);
}
.rl-search__opt { display: block; min-width: 0; max-width: 100%; padding: 9px 12px; border-radius: 7px; cursor: pointer; overflow-wrap: anywhere; word-break: break-word; }
.rl-search__opt strong { display: block; font-size: .93rem; font-weight: 700; line-height: 1.3; }
.rl-search__opt span { display: block; font-size: .78rem; line-height: 1.5; color: var(--muted); }
.rl-search__opt:hover,
.rl-search__opt[aria-selected='true'] { background: var(--mint); }

/* Results bar: the count on the left, small text buttons on the right. */
.rl-results-bar__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0 14px; }

/* "Email me new matches": a plain card under the results bar. */
.rl-alert { margin: -4px 0 26px; }
.rl-alert > * + * { margin-top: 14px; }
.rl-alert__row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: end; max-width: 640px; }
.rl-alert > .rl-link-btn { padding-inline: 0; }
.rl-alert__row .rl-btn { min-height: 46px; }
.rl-alert .rl-f-msg { margin-top: 8px; }
@media (max-width: 520px) {
  .rl-alert__row { grid-template-columns: minmax(0, 1fr); }
}

/* Paging stops at page 40. */
.rl-pager__note { margin: -14px 0 24px; text-align: center; }

/* The 410 page: the similar pets sit apart from the panel, with the same gap as the pet page's
   own sections (.rl-pet: 35px, 50px from 701px). */
.rl-similar { margin-top: 35px; }
@media (min-width: 701px) { .rl-similar { margin-top: 50px; } }

/* Pet page: "Share on Nextdoor" and "Report this listing" sit quietly under the "Listed by" line.
   Plain text links in the site's own style: no Nextdoor logo or colors (Nextdoor's brand rules). */
.rl-stack > .rl-share { margin-top: 6px; }
.rl-stack > .rl-share + .rl-report { margin-top: 0; }
.rl-share__link { display: inline-flex; align-items: center; min-height: 44px; padding: 10px 0; color: var(--forest); font-size: .8rem; font-weight: 500; text-decoration: underline; text-underline-offset: 4px; }
.rl-share__link:hover { color: #173d2b; }
.rl-stack > .rl-report { margin-top: 2px; }
.rl-report__open { min-height: 44px; padding: 10px 0; color: var(--muted); font-size: .74rem; font-weight: 400; }
.rl-report__form { margin-top: 10px; padding: 22px; }
.rl-report__form > * + * { margin-top: 16px; }
.rl-report__form textarea.rl-input { min-height: 110px; resize: vertical; line-height: 1.5; font-family: inherit; }
.rl-report__form .rl-btn-row .rl-link-btn { padding-inline: 4px; }
@media (max-width: 360px) {
  .rl-report__form { padding: 18px; }
}

/* No pets on the site yet: the panel's ways on, centred like its text. */
.rl-panel .rl-btn-row { justify-content: center; }
.rl-panel .rl-panel__more { margin: 18px auto 0; }

/* ==== Search, save and share (2026-11-20, the approved mockup in
   _unpublished/search-share-mockup-2026-11-20/mockup.css). Every color is one the site already
   uses: forest #173f38, mint #edf3f1, clay #b8694d, line #dce3e5, the pill border #c8d5d1 and the
   filter box #f8fafb. ==== */

/* ---- Icons ---------------------------------------------------------------------------- */
.sx-ico { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---- Search: the first box (kind of pet, ZIP, distance) ------------------------------- */
.sx-quick { display: grid; gap: 16px; padding: 16px; background: #f8fafb; border: 1px solid var(--line); border-radius: 12px; }
.sx-quick fieldset,
.sx-panel fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.sx-quick legend,
.sx-panel legend { padding: 0; margin-bottom: 8px; }
.sx-near { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 12px; align-items: end; }
.sx-near .rl-input { padding: 11px 13px; border-color: #7b9699; }
/* The ZIP box is 46px tall (shell.css .rl-input); the distance select and the two buttons beside it
   were 44px, so the two labels and the control tops sat 2px apart. All four are 46px here. */
.sx-near .rl-select, .sx-near .rl-btn { min-height: 46px; }
.sx-near__loc { gap: 8px; padding-inline: 12px; }
.sx-loc-status { grid-column: 1 / -1; display: flex; align-items: flex-start; gap: 8px; font-size: .8rem; line-height: 1.5; color: var(--forest); }
.sx-loc-status:empty { display: none; }
.sx-loc-status .sx-ico { width: 17px; height: 17px; margin-top: 1px; }
.sx-loc-status.is-warn { color: #6f3434; }
.sx-loc-status button { min-height: 44px; margin: -12px 0; padding: 0 4px; background: none; border: 0; color: inherit; font-weight: 600; text-decoration: underline; text-underline-offset: 4px; }
.sx-zip-using::placeholder { color: var(--forest); opacity: 1; font-weight: 500; }
@media (min-width: 701px) {
  .sx-quick { padding: 20px 24px; grid-template-columns: minmax(0, auto) minmax(0, 1fr); gap: 20px 32px; align-items: end; }
  .sx-near { grid-template-columns: minmax(0, 1fr) minmax(0, .8fr) auto auto; }
}
@media (min-width: 701px) and (max-width: 1099px) {
  .sx-quick { grid-template-columns: minmax(0, 1fr); }
}

/* First visit: a friendly start, location first, ZIP code as the other way. */
.sx-first { display: grid; gap: 14px; margin-top: 16px; padding: 22px; background: #f5f1e8; border-color: #f5f1e8; }
.sx-first h2 { font-size: 1.45rem; margin-bottom: 6px; }
.sx-first p { font-size: .88rem; }
.sx-first__act { display: grid; gap: 6px; justify-items: start; }
.sx-first__act .rl-btn { gap: 8px; }
@media (min-width: 701px) { .sx-first { grid-template-columns: minmax(0, 1fr) auto; align-items: center; padding: 24px 28px; } .sx-first__act { justify-items: end; } }

/* Pills: the Pet help filter's pill (resources.css .rl-need), as real radios and checkboxes. */
.sx-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.sx-pill { position: relative; display: inline-flex; min-width: 0; }
.sx-pill input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.sx-pill span { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; padding: 8px 16px; background: #fff; border: 1px solid #c8d5d1; border-radius: 999px; color: #173f38; font-size: .86rem; font-weight: 500; line-height: 1.25; }
.sx-pill:hover span { background: #f5f8f8; border-color: #173f38; }
.sx-pill input:checked + span { background: var(--forest); border-color: var(--forest); color: #fff; }
.sx-pill input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 3px; }
.sx-pill .sx-tick { display: none; width: 15px; height: 15px; }
.sx-pill input:checked + span .sx-tick { display: block; }

/* ---- Search: filters (a side column from 1000px, a bottom sheet on phones) ------------- */
.sx-layout { display: grid; gap: 0; margin-top: 22px; }
@media (min-width: 1000px) { .sx-layout { grid-template-columns: 268px minmax(0, 1fr); gap: 36px; align-items: start; } }

dialog.sx-panel { position: static; display: block; width: auto; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: none; color: inherit; }
dialog.sx-panel:not([open]) { display: none; }
.sx-panel__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 6px; }
.sx-panel__head h2 { font-size: 1.35rem; }
.sx-panel__close { display: none; }
.sx-group { padding: 16px 0; border-bottom: 1px solid var(--line); }
/* A legend sits on the fieldset's top edge, so the space above it is a margin. */
.sx-panel fieldset.sx-group { margin-top: 16px; padding: 0 0 16px; }
.sx-panel fieldset.sx-group:first-child { margin-top: 10px; }
.sx-group:last-child { border-bottom: 0; }
.sx-group .rl-hint { margin-top: 8px; }
.sx-more summary { display: flex; align-items: center; min-height: 44px; font-size: .84rem; font-weight: 700; color: var(--forest); cursor: pointer; }
.sx-more summary::marker { color: var(--muted); }
/* display: flex takes the browser's own triangle away, so "More filters" read as a plain line of
   bold text. The summary draws a chevron that turns when the group opens. */
.sx-more summary { gap: 10px; list-style: none; }
.sx-more summary::-webkit-details-marker { display: none; }
.sx-more summary::after { content: ''; flex: 0 0 auto; width: 7px; height: 7px; margin-top: -4px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); }
.sx-more[open] summary::after { margin-top: 4px; transform: rotate(-135deg); }
.sx-more summary:hover { text-decoration: underline; text-underline-offset: 4px; }
.sx-more[open] summary { margin-bottom: 8px; }
.sx-more .rl-field + .rl-field { margin-top: 14px; }
.sx-panel__foot { display: none; }

/* Phones and tablets: the same filters open as a sheet from the bottom of the screen. */
@media (max-width: 999px) {
  dialog.sx-panel:modal { position: fixed; inset: auto 0 0 0; display: flex; flex-direction: column; width: 100%; max-width: 100%; max-height: min(90vh, 820px); margin: 0; background: #fff; border-radius: 16px 16px 0 0; box-shadow: 0 -10px 40px #102f2b33; }
  dialog.sx-panel::backdrop { background: #09211d73; }
  .sx-panel__head { flex: none; padding: 10px 12px 10px 20px; border-bottom: 1px solid var(--line); }
  .sx-panel__close { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; background: none; border: 0; border-radius: 8px; color: var(--ink); }
  .sx-panel__close:hover { background: #f5f8f8; }
  .sx-panel__body { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 0 20px 12px; }
  .sx-panel__foot { flex: none; display: flex; gap: 12px; align-items: center; padding: 12px 20px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: #fff; }
  .sx-panel__foot .rl-btn { flex: 1; min-height: 48px; }
}

/* ---- Search: results bar, chips, actions ---------------------------------------------- */
.sx-bar { display: grid; gap: 12px; margin: 22px 0 12px; }
@media (min-width: 1000px) { .sx-bar { margin-top: 0; grid-template-columns: minmax(0, 1fr) auto; align-items: end; } }
.sx-count { font-size: .98rem; font-weight: 700; line-height: 1.35; }
.sx-count small { display: block; margin-top: 3px; font-size: .76rem; font-weight: 400; color: var(--muted); }
.sx-tools { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; align-items: end; }
@media (min-width: 521px) and (max-width: 999px) { .sx-tools { grid-template-columns: auto minmax(0, 260px); justify-content: start; } }
.sx-tools .rl-field > label { font-size: .73rem; }
.sx-filter-btn { min-height: 44px; gap: 8px; }
.sx-badge { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; background: var(--forest); border-radius: 11px; color: #fff; font-size: .7rem; font-weight: 700; }
@media (min-width: 1000px) {
  .sx-tools { grid-template-columns: auto; }
  .sx-filter-btn { display: none; }
  .sx-tools .rl-select { min-width: 210px; }
}

.sx-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 6px; padding: 0; list-style: none; }
.sx-chip { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; max-width: 100%; padding: 6px 10px 6px 15px; background: #edf3f1; border: 1px solid #cfded7; border-radius: 999px; color: #173f38; font-size: .8rem; font-weight: 500; line-height: 1.25; text-align: left; }
.sx-chip:hover { background: #e1ebe7; border-color: #173f38; }
.sx-chip .sx-ico { width: 16px; height: 16px; stroke-width: 2.2; }
.sx-chips .rl-link-btn { padding-inline: 6px; }

.sx-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0 18px; margin-bottom: 14px; }
.sx-actions .rl-link-btn { gap: 8px; padding-inline: 0; color: var(--forest); }
.sx-actions a.rl-link-btn { color: var(--forest); }

/* "Save this search": the site's "Email me new matches" card, with plain words. */
.sx-alert { margin: 0 0 22px; }
.sx-alert > * + * { margin-top: 14px; }
.sx-alert h2 { font-size: 1.35rem; }
.sx-alert__search { padding: 12px 14px; background: #f8fafb; border: 1px solid var(--line); border-radius: 8px; font-size: .84rem; }
.sx-alert__row { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; align-items: end; max-width: 640px; }
@media (min-width: 521px) { .sx-alert__row { grid-template-columns: minmax(0, 1fr) auto; } }
.sx-alert__row .rl-btn { min-height: 46px; }
.sx-turnstile { display: flex; align-items: center; gap: 10px; width: 300px; max-width: 100%; min-height: 65px; padding: 10px 14px; background: #fafafa; border: 1px solid #d9d9d9; border-radius: 4px; color: #5c5c5c; font-size: .74rem; }

/* ---- Cards: the site's pet card plus a Save heart -------------------------------------- */
.sx-grid > li { position: relative; }
.sx-heart { position: absolute; top: 10px; right: 10px; z-index: 2; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; background: #ffffffeb; border: 1px solid #dce3e5; border-radius: 50%; color: var(--forest); box-shadow: 0 2px 10px #102f2b1a; }
.sx-heart:hover { background: #fff; border-color: var(--forest); }
.sx-heart .sx-ico { width: 22px; height: 22px; }
.sx-heart[aria-pressed='true'] { color: #b8694d; border-color: #e7d3b9; }
.sx-heart[aria-pressed='true'] .sx-ico { fill: #b8694d; }
.sx-grid .rl-pet-card__name { padding-right: 4px; }

/* ---- No results ------------------------------------------------------------------------ */
.sx-empty { text-align: left; padding: 30px 22px; }
.sx-empty h2 { font-size: 1.7rem; margin-bottom: 10px; }
.sx-empty p { margin: 0 0 16px; max-width: 60ch; }
.sx-empty .sx-try { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 22px; padding: 0; list-style: none; }
.sx-empty .sx-try .rl-btn { gap: 8px; }
.sx-empty .sx-try .rl-btn span { color: var(--muted); font-weight: 400; }
.sx-empty .sx-try .rl-btn:hover span { color: inherit; }
.sx-empty__more { padding-top: 18px; border-top: 1px dashed #c0cabc; }
.sx-empty .rl-btn-row { justify-content: flex-start; }
@media (min-width: 701px) { .sx-empty { padding: 40px 44px; } }

/* ---- Toast: one short line after a save or a copy ------------------------------------- */
.sx-toast { position: fixed; left: 50%; bottom: 20px; z-index: 50; display: flex; align-items: center; gap: 14px; width: max-content; max-width: calc(100vw - 32px); padding: 10px 10px 10px 18px; background: #173f38; border-radius: 10px; box-shadow: 0 10px 30px #102f2b40; color: #fff; font-size: .84rem; line-height: 1.4; transform: translateX(-50%); }
.sx-toast[hidden] { display: none !important; }
.sx-toast a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 8px; color: #fff; font-weight: 600; }
.sx-toast :where(a, button):focus-visible { outline-color: #f5c5a7; }

/* ---- Pet page: Save and Share ----------------------------------------------------------- */
.sx-save { display: grid; gap: 6px; }
.sx-save .rl-btn { gap: 10px; }
.sx-save .rl-btn[aria-pressed='true'] { border-color: #e7d3b9; background: #fdf4ea; color: #4f3a2b; }
.sx-save .rl-btn[aria-pressed='true'] .sx-ico { fill: #b8694d; stroke: #b8694d; }
.sx-save p { font-size: .74rem; line-height: 1.55; color: var(--muted); }
.sx-save p a { color: var(--forest); }

.sx-share { padding-top: 22px; border-top: 1px solid var(--line); }
.sx-share h2 { font-size: 1.35rem; margin-bottom: 6px; }
.sx-share > p { font-size: .84rem; color: var(--muted); }
.sx-share__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 14px 0 0; padding: 0; list-style: none; }
.sx-share__grid .rl-btn { width: 100%; justify-content: flex-start; gap: 10px; padding: 11px 14px; font-size: .84rem; }
.sx-share__grid .sx-share__native { grid-column: 1 / -1; }
.sx-share__grid .sx-share__native .rl-btn { justify-content: center; }
.sx-share__grid .sx-share__kit { grid-column: 1 / -1; }
@media (min-width: 521px) { .sx-share__grid .sx-share__kit { grid-column: auto; } }
/* Tablets: the pet page is two columns from 701px, so half of the share grid is too narrow for
   "Download share kit" on one line. It takes the full row there, as on phones. */
@media (min-width: 701px) and (max-width: 1000px) { .sx-share__grid .sx-share__kit { grid-column: 1 / -1; } }
.sx-share__grid .sx-share__kit .rl-btn { justify-content: center; background: #f5f1e8; border-color: #e7dcc7; color: #173f38; }
.sx-share__grid .sx-share__kit .rl-btn:hover { background: #efe8da; }
.sx-share__status { min-height: 1.4em; margin-top: 8px; font-size: .78rem; color: var(--forest); }
.sx-share .rl-hint { margin-top: 2px; }

/* The share kit: four files, each one row with what it is for. */
.sx-kit { margin-top: 12px; padding: 22px; }
.sx-kit h3 { font-size: 1.2rem; margin-bottom: 6px; }
.sx-kit > p { font-size: .84rem; color: var(--muted); }
.sx-kit__list { margin: 14px 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.sx-kit__list li { border-bottom: 1px solid var(--line); }
.sx-kit__list a { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 14px; align-items: center; min-height: 64px; padding: 10px 0; text-decoration: none; }
.sx-kit__list a:hover strong { text-decoration: underline; text-underline-offset: 4px; }
.sx-kit__list img { width: 56px; height: 56px; object-fit: cover; object-position: top; border: 1px solid var(--line); border-radius: 6px; background: #fff; }
.sx-kit__list strong { display: block; font-size: .88rem; font-weight: 600; line-height: 1.35; }
.sx-kit__list span { display: block; font-size: .74rem; line-height: 1.5; color: var(--muted); }
.sx-kit .rl-small { color: var(--muted); }

/* ---- Saved pets page ------------------------------------------------------------------- */
.sx-saved-top { display: grid; gap: 14px; margin-bottom: 22px; }
@media (min-width: 761px) { .sx-saved-top { grid-template-columns: minmax(0, 1fr) auto; align-items: start; } }
.sx-saved-top .rl-btn { gap: 10px; }
.sx-card-actions { display: flex; gap: 8px; padding: 0 20px 20px; }
.sx-card-actions .rl-btn { flex: 1; min-height: 44px; gap: 8px; padding: 10px 12px; font-size: .78rem; }
.sx-saved .rl-pet-card { height: auto; border-radius: 14px 14px 0 0; border-bottom: 0; box-shadow: none; }
.sx-saved .sx-item { display: flex; flex-direction: column; height: 100%; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 4px 18px #233b3706; overflow: hidden; }
.sx-saved .sx-item .rl-pet-card { border: 0; border-radius: 0; flex: 1; }
.sx-saved .sx-item .rl-pet-card:hover { transform: none; box-shadow: none; }
.sx-saved .sx-item.is-gone .rl-pet-card__photo { display: grid; place-items: center; background: #f1f4f5; }
.sx-saved .sx-item.is-gone .rl-pet-card__photo img { width: 92px; height: 92px; opacity: .7; }
.sx-saved .sx-item.is-gone .rl-pet-card__name { color: var(--muted); }
.sx-banner { margin-bottom: 22px; }
.sx-banner .rl-btn-row { margin-top: 12px; }

/* Share your list: a small dialog in the site's card look. */
.sx-dialog { width: min(520px, calc(100vw - 32px)); padding: 26px; border: 1px solid #dce4dd; border-radius: 12px; color: var(--ink); box-shadow: 0 20px 60px #102f2b33; }
.sx-dialog::backdrop { background: #09211d73; }
.sx-dialog h2 { font-size: 1.5rem; margin-bottom: 8px; }
.sx-dialog > p { font-size: .86rem; color: var(--muted); margin-bottom: 16px; }
.sx-dialog .rl-input { font-size: .82rem; }
.sx-dialog .rl-btn-row { margin-top: 16px; }

@media (prefers-reduced-motion: reduce) { .sx-toast { transition: none; } }
@media (forced-colors: active) {
  .sx-pill input:checked + span, .sx-heart[aria-pressed='true'] { border: 2px solid Highlight; }
}

/* ---- Built on the mockup (2026-11-20) ------------------------------------------------------- */

/* A shorter page top on /pets/, so the first pets show sooner on a phone. */
@media (max-width: 700px) {
  .sx-hero .rl-hero__inner { padding-block: 18px 20px; }
  .sx-hero .rl-hero__eyebrow { margin-bottom: 6px; }
  .sx-hero .rl-hero__title { margin-bottom: 6px; font-size: 1.6rem; }
  .sx-hero .rl-hero__description { font-size: .82rem; line-height: 1.5; }
  .sx-quick { gap: 12px; padding: 14px; }
}
@media (max-width: 1099px) { .sx-hero ~ .rl-wrap { padding-top: 18px; } }

/* The ZIP box's message sits under it without moving the buttons beside it. */
.sx-near .rl-f-msg { margin-top: 4px; }
.sx-near__loc[hidden], .sx-first[hidden] { display: none; }

/* Status words taken out of a pet's name show as tags on the photo (worker/src/petname.mjs). */
.rl-pet-card__tags { position: absolute; left: 12px; top: 13px; right: 64px; display: flex; flex-wrap: wrap; gap: 6px; }
.rl-pet-card__photo .rl-pet-card__tags .rl-tag { position: static; }
.rl-pet__tags { display: flex; flex-wrap: wrap; gap: 6px; }

/* No results: the buttons that change one thing. */
.sx-try:empty { display: none; }

/* Save this search. */
.sx-alert .sx-alert__zip .rl-input { max-width: 220px; }
.sx-alert .rl-f-msg { margin-top: 8px; }
.sx-alert__close { padding-inline: 0; }

/* Saved pets: the "No longer listed" card's line. */
.sx-saved .sx-gone-note { margin-top: 8px; }
.sx-card-actions .rl-btn[disabled] { opacity: .55; }

/* The share kit panel. */
.sx-kit__status { margin-top: 10px; font-size: .84rem; color: var(--forest); }
.sx-kit h3:focus { outline: none; }
.sx-kit h3:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }

/* The toast sits above the chat button on phones. */
@media (max-width: 760px) { .sx-toast { bottom: calc(84px + env(safe-area-inset-bottom, 0px)); } }

/* The phone filter sheet covers the chat button (it is under the page's dimmed backdrop anyway). */
.sx-panel__head h2:focus { outline: none; }
.sx-panel__head h2:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }

/* The chat button steps aside while a search control is under it (site/rl/pets.js watchChat). */
.rl-chat-launch { transition: opacity .15s; }
.sx-chat-aside .rl-chat-launch { visibility: hidden; opacity: 0; }
@media (prefers-reduced-motion: reduce) { .rl-chat-launch { transition: none; } }

/* ---- Phones: two pets a row (shell.css) ---------------------------------------------------- */
/* The heart keeps its 44px and moves closer to the corner; the tags sit at the foot of the photo,
   clear of it. The Saved pets buttons stack, so each keeps its words. */
@media (max-width: 700px) {
  .sx-heart { top: 6px; right: 6px; }
  .rl-pet-card__tags { left: 8px; right: 8px; top: auto; bottom: 8px; gap: 4px; }
  .sx-card-actions { flex-direction: column; padding: 0 12px 12px; }
  .sx-card-actions .rl-btn { flex: 0 0 auto; padding: 10px 8px; }
}

/* ---- Pet page on a phone: the Ask button stays in reach (site/rl/pet.js askBar) ------------- */
/* A bar at the foot of the screen with the pet's name, Save and the Ask link. pet.js shows it only
   while the page's own Ask button, the Share section and the footer are all off screen, so it never
   covers them. Above the iPhone home bar; the chat button and the toast move up while it shows. */
.rl-askbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 55; display: flex; align-items: center; gap: 10px; padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px)); background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -8px 24px #102f2b14; }
.rl-askbar[hidden] { display: none; }
.rl-askbar__text { flex: 1 1 0; min-width: 0; }
.rl-askbar__text strong,
.rl-askbar__text span { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.rl-askbar__text strong { font-size: 1rem; font-weight: 600; line-height: 1.25; color: var(--forest); }
.rl-askbar__text span { font-size: .74rem; line-height: 1.4; color: var(--muted); }
.rl-askbar .sx-heart { position: static; flex: 0 0 44px; box-shadow: none; }
.rl-askbar .rl-btn { flex: 0 1 auto; min-width: 0; padding: 12px 16px; }
/* Keyboard focus never lands under the bar (WCAG 2.4.11). */
html.rl-askbar-on { scroll-padding-bottom: calc(88px + env(safe-area-inset-bottom, 0px)); }
html.rl-askbar-on .rl-chat-launch,
html.rl-askbar-on .rl-chat-launch.rl-btn { bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
.rl-askbar-on .sx-toast { bottom: calc(148px + env(safe-area-inset-bottom, 0px)); }
@media (max-width: 360px) {
  .rl-askbar { gap: 8px; padding-inline: 12px; }
  .rl-askbar .rl-btn { padding-inline: 12px; font-size: .82rem; }
}
@media (min-width: 701px) { .rl-askbar { display: none; } }
@media print { .rl-askbar { display: none; } }
