/* Business picker component — shared across the landing, dashboard-claim, and
 * /setup pages. Previously this ruleset was injected at runtime by
 * public/js/business-search.js via installStyles(); it moved here in Batch 2.2
 * so every mount gets the same CSS from the browser cache instead of each
 * script execution creating its own <style> tag.
 *
 * The three pages that use the picker include this stylesheet with
 * <link rel="stylesheet" href="/css/business-search.css?v=4">. Keep it in sync
 * when the component's markup changes (data-business-search-* attributes). */
.business-search {
  position: relative;
  z-index: 10;
  display: block !important;
  width: 100%;
  margin-bottom: 12px;
}
.business-search-control {
  position: relative !important;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  width: 100%;
  overflow: visible !important;
  border-radius: 30px;
  border: 1px solid var(--border, #d9ddd4);
  background: #fff;
  box-shadow: 0 8px 22px rgba(218, 223, 186, 0.32);
  transition: box-shadow 0.2s ease;
}
.business-search-control:focus-within {
  border-color: var(--text-olive, #464c1c);
  box-shadow:
    0 0 0 4px rgba(218, 223, 186, 0.42),
    0 10px 26px rgba(218, 223, 186, 0.36);
}
.business-search-control .search-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: #5f6460;
  z-index: 1;
  pointer-events: none;
}
html[dir='rtl'] .business-search-control .search-icon {
  left: auto;
  right: 16px;
}
.business-search-control [data-business-search-input] {
  width: 100%;
  min-width: 0;
  min-height: 56px;
  border: 0;
  border-radius: 30px;
  background: transparent;
  box-shadow: none !important;
  font-size: 16px;
  /* The button occupies its own grid column, so no guessed width is reserved. */
  padding-inline-start: 44px !important;
  padding-inline-end: 10px !important;
}
.business-search-control:has(input.error) {
  border-color: #e11d48;
}
html[dir='rtl'] .business-search-control [data-business-search-input] {
  direction: rtl !important;
  text-align: right !important;
}
.business-search-control .btn-primary {
  position: static;
  z-index: 1;
  align-self: stretch;
  width: auto;
  margin: 5px;
  height: auto;
  min-width: 0;
  min-height: 44px;
  padding: 0 16px;
  white-space: nowrap;
}
.business-search-launch:disabled {
  cursor: not-allowed;
  opacity: 0.5;
  filter: saturate(0.55);
}
.business-search-launch.is-ready svg {
  animation: business-search-launch-pop 0.32s ease-out;
}
@keyframes business-search-launch-pop {
  50% {
    transform: translate(2px, -2px) scale(1.12);
  }
}
.business-search-results[hidden] {
  display: none !important;
}
.business-search-results {
  position: absolute !important;
  z-index: 20;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  display: grid;
  max-height: var(--business-search-tray-height, 240px);
  overflow: auto;
  overscroll-behavior: contain;
  background: #fff;
  border: 1px solid rgba(36, 45, 38, 0.18);
  border-radius: 10px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
}
.business-search-results.is-above {
  top: auto;
  bottom: calc(100% + 4px);
}
.business-search-result {
  display: block;
  width: 100%;
  padding: 12px 14px;
  border: 0;
  border-bottom: 1px solid rgba(36, 45, 38, 0.08);
  background: #fff;
  color: #242d26;
  text-align: left;
  font: inherit;
  cursor: pointer;
}
.business-search-result:hover,
.business-search-result:focus,
.business-search-result.is-active {
  background: #f5f6ee;
  outline: none;
}
.business-search-status {
  position: absolute;
  z-index: 20;
  top: calc(100% + 4px);
  inset-inline-start: 0;
  width: 100%;
  font-size: 12px;
  color: #5f6460;
}
.business-search-status:empty {
  display: none;
}
.business-search-match {
  font-weight: 700;
}
.business-search-google-mark {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 7px 14px 8px;
  color: #5f6460;
  font:
    italic 400 10px/1 Arial,
    sans-serif;
  letter-spacing: 0.01em;
  text-align: right;
}
.business-search-google-logo {
  display: block;
  width: 11px;
  height: 11px;
}
@media (prefers-reduced-motion: reduce) {
  .business-search-launch.is-ready svg {
    animation: none;
  }
}
@media (max-width: 480px) {
  /* Both columns remain inside the pill; localized labels size naturally. */
  .business-search-control .btn-primary {
    padding: 0 14px;
    font-size: 14px;
  }
}
