/*
 * Liscano Power · Search Predictive 2.2
 * Progressive enhancement of #lco-search-panel, not a new search bar.
 * Uses Design System V2 tokens and keeps the existing search modal untouched.
 */
body.lco-editorial #lco-search-panel .lco-predictive-layout {
  display: grid;
  grid-template-columns: minmax(190px, 34%) minmax(0, 1fr);
  min-width: 0;
  margin: -16px -35px -30px;
  border-top: 1px solid var(--lco-ds-border, #ededed);
  background: #fff;
  border-radius: 0 0 var(--lco-ds-radius-panel, 24px) var(--lco-ds-radius-panel, 24px);
  overflow: hidden;
}
body.lco-editorial #lco-search-panel .lco-predictive-side {
  min-width: 0;
  padding: 24px 20px 28px 35px;
  background: #f7f7f7;
  border-right: 1px solid var(--lco-ds-border, #eee);
}
body.lco-editorial #lco-search-panel .lco-predictive-main {
  min-width: 0;
  padding: 24px 29px 27px;
}
body.lco-editorial #lco-search-panel .lco-predictive-label {
  margin: 0 0 12px;
  font: inherit;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: .11em;
  text-transform: uppercase;
  color: var(--lco-ds-muted, #6d6d70);
}
body.lco-editorial #lco-search-panel .lco-predictive-collections-title {
  margin-top: 28px;
}
body.lco-editorial #lco-search-panel .lco-predictive-suggestions,
body.lco-editorial #lco-search-panel .lco-predictive-collections {
  display: grid;
  gap: 3px;
}
body.lco-editorial #lco-search-panel .lco-predictive-side a {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 34px;
  padding: 6px 9px;
  margin: 0;
  border-radius: var(--lco-ds-radius-control, 12px);
  color: var(--lco-ds-ink, #252525);
  text-decoration: none;
  font-size: 13px;
  font-weight: 580;
  line-height: 1.35;
  white-space: normal;
  overflow-wrap: anywhere;
}
body.lco-editorial #lco-search-panel .lco-predictive-suggestion:first-child {
  font-weight: 750;
}
body.lco-editorial #lco-search-panel .lco-predictive-side a:hover,
body.lco-editorial #lco-search-panel .lco-predictive-side a:focus-visible,
body.lco-editorial #lco-search-panel .lco-predictive-side a.is-keyboard-active {
  color: var(--lco-ds-ink, #171717);
  background: #ececed;
}
body.lco-editorial #lco-search-panel .lco-predictive-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 4px;
}
body.lco-editorial #lco-search-panel .lco-predictive-products {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
body.lco-editorial #lco-search-panel .lco-predictive-product {
  display: grid;
  grid-template-columns: 66px minmax(0, 1fr) auto;
  align-items: center;
  column-gap: 13px;
  min-width: 0;
  padding: 11px 5px;
  color: var(--lco-ds-ink, #1a1a1a);
  border-top: 1px solid var(--lco-ds-border, #e9e9ea);
  border-radius: 0;
  text-decoration: none;
}
body.lco-editorial #lco-search-panel .lco-predictive-product:hover,
body.lco-editorial #lco-search-panel .lco-predictive-product:focus-visible,
body.lco-editorial #lco-search-panel .lco-predictive-product.is-keyboard-active {
  background: #f8f8f9;
}
body.lco-editorial #lco-search-panel .lco-predictive-product-image,
body.lco-editorial #lco-search-panel .lco-predictive-product-placeholder {
  width: 66px;
  height: 67px;
  border-radius: var(--lco-ds-radius-control, 12px);
  background: #f1f1f1;
  object-fit: contain;
  flex-shrink: 0;
}
body.lco-editorial #lco-search-panel .lco-predictive-product-placeholder {
  display: grid;
  place-items: center;
  color: #999;
  font-size: 11px;
  font-weight: 700;
}
body.lco-editorial #lco-search-panel .lco-predictive-product-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
  overflow-wrap: anywhere;
}
body.lco-editorial #lco-search-panel .lco-predictive-product-name {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  max-height: 2.8em;
  overflow: hidden;
  font-size: 13px;
  line-height: 1.4;
  font-weight: 680;
  letter-spacing: -.008em;
}
body.lco-editorial #lco-search-panel .lco-predictive-product-category {
  color: var(--lco-ds-muted, #858585);
  font-size: 12px;
  line-height: 1.3;
  text-transform: none;
}
body.lco-editorial #lco-search-panel .lco-predictive-product-price {
  justify-self: end;
  text-align: right;
  max-width: 130px;
  color: var(--lco-ds-accent, #c31839);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.4;
  overflow-wrap: anywhere;
  font-variant-numeric: tabular-nums;
}
body.lco-editorial #lco-search-panel .lco-predictive-main .lco-predictive-all {
  display: flex;
  width: fit-content;
  min-height: 42px;
  margin: 16px auto 0;
  padding: 12px 23px;
  border: 0;
  border-radius: 999px;
  background: var(--lco-ds-ink, #191919);
  color: #fff;
  font-size: 12px;
  font-weight: 750;
  text-align: center;
}
body.lco-editorial #lco-search-panel .lco-predictive-main .lco-predictive-all:hover {
  background: var(--lco-ds-accent, #c31839);
}
body.lco-editorial #lco-search-panel .lco-predictive-layout a:focus-visible,
body.lco-editorial #lco-search-panel .lco-predictive-all:focus-visible {
  outline: 2px solid var(--lco-ds-ring, #bd1734);
  outline-offset: 2px;
}
body.lco-editorial #lco-search-panel .lco-search-results > .lco-predictive-all {
  margin-top: 12px;
  border-radius: var(--lco-ds-radius-control, 12px);
}
@media (max-width: 767px) {
  body.lco-editorial #lco-search-panel .lco-predictive-layout {
    grid-template-columns: minmax(0, 1fr) !important;
    margin: -10px -16px -16px;
    border-radius: 0;
  }
  body.lco-editorial #lco-search-panel .lco-predictive-side {
    padding: 17px 16px 14px;
    border-right: 0;
    border-bottom: 1px solid var(--lco-ds-border, #eee);
  }
  body.lco-editorial #lco-search-panel .lco-predictive-side a {
    min-height: 32px;
    font-size: 12px;
  }
  body.lco-editorial #lco-search-panel .lco-predictive-collections-title {
    margin-top: 16px;
  }
  body.lco-editorial #lco-search-panel .lco-predictive-main {
    padding: 18px 16px 28px;
  }
  body.lco-editorial #lco-search-panel .lco-predictive-product {
    grid-template-columns: 58px minmax(0, 1fr);
    row-gap: 3px;
    column-gap: 10px;
    padding: 11px 0;
  }
  body.lco-editorial #lco-search-panel .lco-predictive-product-image,
  body.lco-editorial #lco-search-panel .lco-predictive-product-placeholder {
    width: 58px;
    height: 62px;
    grid-row: span 2;
  }
  body.lco-editorial #lco-search-panel .lco-predictive-product-name {
    font-size: 12px;
  }
  body.lco-editorial #lco-search-panel .lco-predictive-product-category {
    font-size: 11px;
  }
  body.lco-editorial #lco-search-panel .lco-predictive-product-price {
    grid-column: 2;
    justify-self: start;
    text-align: left;
    max-width: 100%;
    font-size: 12px;
  }
  body.lco-editorial #lco-search-panel .lco-predictive-main .lco-predictive-all {
    width: 100%;
  }
}
@media (max-width: 350px) {
  body.lco-editorial #lco-search-panel .lco-predictive-layout {
    margin-inline: -13px;
  }
  body.lco-editorial #lco-search-panel .lco-predictive-main,
  body.lco-editorial #lco-search-panel .lco-predictive-side {
    padding-inline: 13px;
  }
}
@media (prefers-reduced-motion: reduce) {
  body.lco-editorial #lco-search-panel .lco-predictive-layout a {
    transition: none;
  }
}

/* The V2 pane is intentionally contained within the CURRENT search dialog.
   Older global modal styles remain untouched. The stylesheet is server
   enqueued after the existing search CSS rather than injected from JS. */
body.lco-editorial #lco-search-panel .lco-search-results:not([hidden]) {
  display: block;
  min-width: 0;
  width: 100%;
}
body.lco-editorial #lco-search-panel .lco-predictive-layout {
  border-top: 1px solid var(--lco-ds-border, #ededed);
}
body.lco-editorial #lco-search-panel .lco-predictive-categories-empty,
body.lco-editorial #lco-search-panel .lco-predictive-empty {
  margin: 12px 0;
  color: var(--lco-ds-muted, #6d6d70);
  font-size: 12px;
  line-height: 1.5;
}
body.lco-editorial #lco-search-panel .lco-predictive-main .lco-predictive-empty {
  padding: 20px 0;
}
body.lco-editorial #lco-search-panel .lco-predictive-collections {
  max-height: 310px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}
@media (max-width: 767px) {
  body.lco-editorial #lco-search-panel .lco-predictive-collections {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 5px;
    max-height: 155px;
  }
  body.lco-editorial #lco-search-panel .lco-predictive-side .lco-predictive-collection {
    min-width: 0;
    font-size: 11px;
  }
}
