.bottom-area {
  position: fixed;
  right: 0;
  bottom: calc(0px - var(--keyboard-offset));
  left: 0;
  z-index: 90;
  padding: 4px 0 0;
  isolation: isolate;
  background: linear-gradient(180deg, transparent 0%, rgb(18 4 7 / 92%) 13%, #120407 30%);
  animation: landingDockSlideUp var(--landing-slide-duration) cubic-bezier(0.22, 0.76, 0.2, 1) both;
  backface-visibility: hidden;
  transform-style: preserve-3d;
}

.bottom-area::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  z-index: 4;
  display: none;
  height: 1px;
  background: var(--v17-hairline);
  opacity: 0.86;
  box-shadow: 0 0 5px rgb(194 139 60 / 24%);
  pointer-events: none;
}

.bottom-area::after {
  content: "";
  position: absolute;
  top: 100%;
  right: 0;
  left: 0;
  height: 120px;
  background: #120407;
}

.search-control-line {
  position: relative;
  display: grid;
  width: min(calc(100% - 16px), 760px);
  grid-template-columns: minmax(0, 1fr);
  min-height: 54px;
  align-items: center;
  gap: 10px;
  margin: 0 auto;
  transition: transform 180ms ease;
}

body.keyboard-visible .search-control-line {
  transform: translateY(calc(58px + var(--safe-bottom) - var(--keyboard-offset) - var(--keyboard-offset)));
}

.search-control-line .labeled-search {
  grid-column: 1 / -1;
  grid-row: 1;
  width: 100%;
  min-width: 0;
  height: 48px;
  justify-self: stretch;
  margin-right: 0;
  max-width: 100%;
  opacity: 1;
  visibility: visible;
  transition: none;
}

.search-wrap.labeled-search {
  border: 0;
  border-radius: 999px;
  background: transparent;
  box-shadow: none;
}

.search-control-line .main-search {
  width: 100%;
  min-width: 0;
  height: 48px;
  min-height: 48px;
  padding: 0 46px 0 56px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #ddd4c8;
  box-shadow: none;
  touch-action: manipulation;
  font-size: 16px;
}

.search-control-line .main-search::-webkit-search-cancel-button {
  appearance: none;
}

/* stylelint-disable declaration-no-important -- Override the shared legacy search glow radius for this pill only. */
.search-control-line .labeled-search::after {
  inset: -1px auto auto -1px;
  width: calc(100% + 2px);
  height: 50px;
  padding: 1px;
  transition: width 0.4s ease, left 0.4s ease;
  border-radius: 999px !important;
  filter: drop-shadow(0 0 2px rgb(222 153 57 / 24%));
  animation: none;
  background-position: 0 0;
}

.search-control-line .labeled-search:focus-within::after {
  animation: activeBrassBorderSweep 1.8s linear infinite;
}

/* stylelint-enable declaration-no-important */
.search-toggle svg {
  display: block;
  width: 22px;
  height: 22px;
  margin: auto;
  fill: none;
  stroke: currentcolor;
  stroke-linecap: round;
  stroke-width: 1.7;
}

.search-toggle:focus-visible {
  outline: 2px solid #f0cc84;
  outline-offset: 3px;
}

.landing-search-clear {
  width: 28px;
  min-width: 28px;
  padding: 0;
  border-radius: 50%;
  background: transparent;
  font-size: 1.3rem;
}

.landing-search-clear[hidden] {
  display: none;
}

.inline-search-actions {
  position: absolute;
  top: 50%;
  right: 5px;
  z-index: 20;
  display: flex;
  align-items: center;
  height: 40px;
  gap: 0;
  transform: translateY(-50%);
}

.inline-search-actions button {
  height: 36px;
  min-height: 36px;
  border: 0;
  color: var(--v15-beige);
  font-weight: 800;
  animation: none;
  box-shadow: none;
}

.hash-toggle {
  position: relative;
  z-index: 21;
  grid-column: 1;
  grid-row: 1;
  width: 48px;
  min-width: 48px;
  height: 48px;
  min-height: 48px;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 50%;
  background: linear-gradient(#3b0d1b, #250811) padding-box, var(--v172-metal-line) border-box;
  color: #c49a69;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.58rem;
  line-height: 1;
  box-shadow: 0 4px 12px rgb(0 0 0 / 22%);
  justify-self: center;
}

.hash-toggle:active {
  background: rgb(177 139 95 / 25%);
  transform: scale(0.94);
}

.hash-toggle.active-filter {
  color: #f1dfb9;
  filter: drop-shadow(0 0 4px rgb(226 196 135 / 65%));
}

/* The magnifier stays inside the permanently extended search pill. */
.search-control-line > .search-toggle {
  position: absolute;
  left: 0;
  top: 3px;
  transition: none;
}

.integrated-apply {
  display: grid;
  width: 36px;
  min-width: 36px;
  padding: 0;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(180deg, rgb(82 20 38 / 88%), rgb(43 10 20 / 94%));
  color: #cbb083;
  font-size: 0.72rem;
  letter-spacing: 0.015em;
  box-shadow: inset 0 1px rgb(255 255 255 / 3.5%);
}

.integrated-apply:active {
  transform: scale(0.94);
}

.integrated-apply svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentcolor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.75;
}

.search-control-line .labeled-search::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 100%;
  border-radius: 999px;
  background: #111011;
  transition: width 0.4s ease, left 0.4s ease;
  pointer-events: none;
}

.landing-unified {
  position: relative;
  height: 48px;
  transition: opacity 0.18s ease;
}

.landing-unified.has-search-text .main-search {
  padding-right: 78px;
}

.main-search::placeholder {
  font-size: var(--placeholder-size, 14px);
}

.id-row {
  position: absolute;
  inset: 0 0 0 56px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.22s ease, visibility 0s 0.4s;
}

.landing-id-field {
  position: relative;
}

.landing-id-field input {
  height: 48px;
  min-height: 48px;
  padding: 0 28px 0 12px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #ddd4c8;
  box-shadow: none;
  font-size: 16px;
}

.landing-id-field:last-child {
  border: 1px solid transparent;
  border-radius: 999px;
  background: linear-gradient(#111011, #111011) padding-box, var(--v172-metal-soft) border-box;
  transform: translateX(-20px);
  transition: transform 0.4s ease;
}

.landing-id-field:last-child input {
  height: 46px;
  min-height: 46px;
}

.search-mode-hash {
  display: none;
}

.search-toggle.search-mode-ids svg {
  display: none;
}

.search-mode-ids .search-mode-hash {
  display: block;
}

.search-mode-ids .landing-unified {
  opacity: 0;
  visibility: hidden;
}

.search-mode-ids .id-row {
  opacity: 1;
  visibility: visible;
  transition-delay: 0.08s, 0s;
}

.search-mode-ids .landing-id-field:last-child {
  transform: none;
}

.search-control-line .search-mode-ids::before {
  left: 56px;
  width: calc((100% - 64px) / 2);
}

.search-control-line .search-mode-ids::after {
  left: 55px;
  width: calc((100% - 64px) / 2 + 2px);
}

@media (prefers-reduced-motion: reduce) {
  .search-control-line .labeled-search,
  .search-control-line .labeled-search::before,
  .search-control-line .labeled-search::after,
  .landing-unified,
  .id-row,
  .landing-id-field:last-child {
    transition: none;
  }

  .search-control-line > .search-toggle {
    transition: none;
  }

  .search-control-line .labeled-search::after {
    animation: none !important; /* stylelint-disable-line declaration-no-important -- Overrides legacy shimmer. */
  }
}

.suggestions {
  position: absolute;
  right: 0;
  bottom: calc(100% + 8px);
  left: 0;
  z-index: 130;
  display: none;
  max-height: 260px;
  overflow: auto;
  border: 1px solid rgb(177 139 95 / 28%);
  border-radius: 14px;
  background: #171415;
  box-shadow: 0 12px 28px rgb(0 0 0 / 46%);
}

.suggestions.open {
  display: block;
}

.suggestion {
  padding: 12px 13px;
  border-bottom: 1px solid rgb(177 139 95 / 11%);
  color: #cfc3b5;
  font-size: 0.93rem;
  font-weight: 700;
  line-height: 1.18;
}

.suggestion:active {
  background: #471222;
}

.suggestion.match-start {
  color: #dfcfb9;
}

.dock-btn {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 54px;
  min-height: 54px;
  gap: 5px;
  margin: 0;
  padding: 2px;
  border: 0;
  border-radius: 16px;
  background: transparent;
  color: var(--v15-logo-warm);
  font-size: 0.67rem;
  font-weight: 680;
  line-height: 1;
  text-shadow: none;
  visibility: visible;
  opacity: 1;
  isolation: auto;
  transform: none;
  animation: none;
  box-shadow: none;
}

.dock-actions {
  position: relative;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  width: 100vw;
  min-height: 62px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: stretch;
  gap: 0;
  box-sizing: border-box;
  margin: 8px 0 0;
  padding: 2px 4px calc(2px + var(--safe-bottom));
  border: 0;
  border-radius: 0;
  background: linear-gradient(180deg, #4b2022 0%, #351517 57%, #241013 100%);
}

.dock-actions::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 1px;
  background: var(--v172-metal-line);
  opacity: 0.82;
  box-shadow: 0 0 4px rgb(160 78 46 / 24%);
  pointer-events: none;
}

.persistent-drawer-dock {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 2147483647;
  display: none;
  width: 100vw;
  min-height: 62px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  box-sizing: border-box;
  margin-right: 0;
  margin-left: 0;
  padding: 2px 4px calc(2px + var(--safe-bottom));
  border: 0;
  background: linear-gradient(180deg, #4b2022 0%, #351517 57%, #241013 100%);
  box-shadow: inset 0 1px rgb(177 139 95 / 20%);
  transform: none;
  backface-visibility: hidden;
  transform-style: preserve-3d;
}

body.drawer-open .persistent-drawer-dock,
body.drawer-closing .persistent-drawer-dock {
  display: grid;
}

.persistent-drawer-dock::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  z-index: 4;
  display: block;
  height: 1px;
  background: var(--v172-metal-line);
  opacity: 0.82;
  box-shadow: none;
  pointer-events: none;
}

.applied-filter-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  align-items: center;
  gap: 7px;
  margin: 6px 8px 0;
}
