/* catalog-search.css
   Scoped styles for the du-catalog-search block only.
   Palette: navy #0b1749, blue #1956ee, border #dce6f5, white surface.
   No global selectors, no external fonts/JS/dependencies. */

.du-catalog-search,
.du-catalog-search *,
.du-catalog-search *::before,
.du-catalog-search *::after {
  box-sizing: border-box;
}

/* ---- form shell (home search row + results form) ---- */
.elementor-page-135 .elementor-element-d400f1a > .elementor-container > .elementor-column:has(form.du-catalog-search) { width:100%!important; }
.elementor-page-135 .elementor-element-d400f1a > .elementor-container > .elementor-column:not(:has(form.du-catalog-search)) { display:none; }
.du-catalog-search {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0;
  color: #0b1749;
  font-family: inherit;
  font-size: 16px;
  line-height: 1.35;
}

/* ---- search row: input grows, button keeps its natural width ---- */
.du-catalog-row {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 12px;
  width: 100%;
}

.du-catalog-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  flex: 1 1 320px;
  min-width: 0;
}

.du-catalog-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  color: #1956ee;
  pointer-events: none;
}

form.du-catalog-search input.du-catalog-input[type="search"] {
  width: 100%;
  min-width: 0;
  min-height: 48px;
  padding: 10px 16px;
  padding-left: 48px !important; /* keeps text clear of the icon over theme resets */
  font-family: inherit;
  font-size: 16px;
  color: #0b1749;
  background: #ffffff;
  border: 1px solid #bdcce5 !important;
  border-radius: 10px;
  appearance: none;
}

.du-catalog-input::placeholder {
  color: #5a6a94;
  opacity: 1;
}

form.du-catalog-search button.du-catalog-submit {
  flex: 0 0 auto;
  width: auto;
  min-width: 160px;
  min-height: 48px;
  padding: 0 28px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  color: #ffffff;
  background: #1956ee;
  border: 1px solid #1956ee;
  border-radius: 10px;
  cursor: pointer;
}

form.du-catalog-search button.du-catalog-submit:hover,
.du-catalog-filter-actions > button:hover {
  background: #0b1749;
  border-color: #0b1749;
}

/* ---- results filters: collapsed details under the row ---- */
.du-catalog-filters {
  margin-top: 16px;
  padding: 4px 16px 16px;
  background: #ffffff;
  border: 1px solid #dce6f5;
  border-radius: 10px;
}

.du-catalog-filters > summary {
  padding: 14px 0;
  font-size: 16px;
  font-weight: 600;
  color: #0b1749;
  cursor: pointer;
}

.du-catalog-filter-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 8px;
}

.du-catalog-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  font-size: 16px;
  font-weight: 600;
  color: #0b1749;
}

.du-catalog-field > select {
  width: 100%;
  min-width: 0;
  min-height: 46px;
  padding: 8px 12px;
  font-family: inherit;
  font-size: 16px;
  color: #0b1749;
  background: #ffffff;
  border: 1px solid #dce6f5;
  border-radius: 8px;
}

.du-catalog-filter-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
}

form.du-catalog-search .du-catalog-filter-actions > button {
  width: auto;
  min-height: 46px;
  padding: 0 24px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  color: #ffffff;
  background: #1956ee;
  border: 1px solid #1956ee;
  border-radius: 8px;
  cursor: pointer;
}

.du-catalog-filter-actions > button[type="reset"] {
  color: #0b1749;
  background: #ffffff;
  border-color: #dce6f5;
}

/* ---- accessible focus ---- */
.du-catalog-search input:focus-visible,
.du-catalog-search select:focus-visible,
.du-catalog-search button:focus-visible,
.du-catalog-search summary:focus-visible {
  outline: 3px solid #1956ee;
  outline-offset: 2px;
}

/* ---- responsive ---- */
.du-catalog-search > .du-catalog-label { display:block; margin-bottom:10px; font-weight:600; }
.du-catalog-search .du-catalog-note { font-size:13px; color:#526787; margin:12px 0; }
.du-catalog-search .du-catalog-chips { list-style:none; padding:0; display:flex; flex-wrap:wrap; gap:8px; }
.du-catalog-search .du-catalog-chip { font-size:13px; padding:6px 10px; background:#eef4ff; border-radius:6px; overflow-wrap:anywhere; }
.du-catalog-search .du-catalog-reset { color:#1748bf; min-height:44px; display:inline-flex; align-items:center; padding:8px 12px; }
@media (max-width: 800px) {
  .du-catalog-filter-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .du-catalog-row {
    flex-direction: column;
  }

  .du-catalog-input-wrap,
  .du-catalog-submit {
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
  }

  .du-catalog-filter-actions > button {
    flex: 1 1 auto;
  }
}
