/**
 * Poisk — unified search field (design system).
 * Reference: company picker "Поиск по email" (rounded white field + gray placeholder).
 * Placeholder text stays page-specific (what we search); this file only unifies look/size.
 */

:root {
  --poisk-font-family: Arial, sans-serif;
  --poisk-font-size: 14px;
  --poisk-font-weight: 400;
  --poisk-line-height: 1.3;
  --poisk-padding-y: 9px;
  --poisk-padding-x: 12px;
  --poisk-radius: 8px;
  --poisk-border: #cbd5e1;
  --poisk-border-focus: #93c5fd;
  --poisk-bg: #ffffff;
  --poisk-color: #0f172a;
  --poisk-placeholder: #94a3b8;
  --poisk-min-height: 38px;
}

/* Canonical class + type=search; page keeps id/name/JS hooks and width/flex layout */
.poisk,
input.poisk,
input[type="search"]:not(.poisk-skip),
.sl-search-row input[type="search"],
.sl-search-row input[type="text"],
.sl-country-picker-query,
.mail-search,
.max-search,
.max-company-search,
.catalog-search,
.dela-search input[type="search"],
.dela-toolbar input[type="search"],
.ok-search-wrap input[type="search"],
.bx-search input[type="search"],
.bx-search input[type="text"],
.bx-search-wrap input[type="search"],
.pz-search-wrap input[type="search"],
.zl-table-toolbar input[type="search"],
.zv-search-wrap input[type="search"],
.zv-search-wrap input[type="text"].zv-input,
.dz-company-search-wrap input[type="search"],
.nz-counterparty-search-wrap input[type="search"],
.sp-search-field input[type="search"],
.rmb-field input[type="search"],
.btr-field input[type="search"],
.cr-field input[type="search"],
.pr-field input[type="search"],
.urr-field input[type="search"],
.bitrix-search-wrap input[type="search"],
.bitrix-search-wrap input[type="text"],
#zerno-dash-search,
#linkCompanySearch,
#mailSearch,
#rights-user-filter,
#mmSearch {
  box-sizing: border-box;
  min-height: var(--poisk-min-height);
  padding: var(--poisk-padding-y) var(--poisk-padding-x);
  border: 1px solid var(--poisk-border);
  border-radius: var(--poisk-radius);
  background: var(--poisk-bg);
  color: var(--poisk-color);
  font-family: var(--poisk-font-family);
  font-size: var(--poisk-font-size);
  font-weight: var(--poisk-font-weight);
  line-height: var(--poisk-line-height);
}

.poisk::placeholder,
input.poisk::placeholder,
input[type="search"]:not(.poisk-skip)::placeholder,
.sl-search-row input::placeholder,
.sl-country-picker-query::placeholder,
.mail-search::placeholder,
.max-search::placeholder,
.max-company-search::placeholder,
.catalog-search::placeholder,
.dela-search input::placeholder,
.ok-search-wrap input::placeholder,
.bx-search input::placeholder,
.pz-search-wrap input::placeholder,
.zl-table-toolbar input[type="search"]::placeholder,
.zv-search-wrap input::placeholder,
.dz-company-search-wrap input::placeholder,
.nz-counterparty-search-wrap input::placeholder,
.sp-search-field input::placeholder,
.rmb-field input[type="search"]::placeholder,
.btr-field input[type="search"]::placeholder,
.cr-field input[type="search"]::placeholder,
.pr-field input[type="search"]::placeholder,
.urr-field input[type="search"]::placeholder,
.bitrix-search-wrap input::placeholder,
#zerno-dash-search::placeholder,
#linkCompanySearch::placeholder,
#mailSearch::placeholder,
#rights-user-filter::placeholder,
#mmSearch::placeholder {
  color: var(--poisk-placeholder);
  opacity: 1;
}

.poisk:focus,
input.poisk:focus,
input[type="search"]:not(.poisk-skip):focus,
.sl-search-row input:focus,
.mail-search:focus,
.max-search:focus,
.max-company-search:focus,
.catalog-search:focus,
.dela-search input:focus,
.ok-search-wrap input:focus,
.bx-search input:focus,
.pz-search-wrap input:focus,
.zl-table-toolbar input[type="search"]:focus,
.zv-search-wrap input:focus,
.dz-company-search-wrap input:focus,
.nz-counterparty-search-wrap input:focus,
.sp-search-field input:focus,
.rmb-field input[type="search"]:focus,
.btr-field input[type="search"]:focus,
.cr-field input[type="search"]:focus,
.pr-field input[type="search"]:focus,
.urr-field input[type="search"]:focus,
.bitrix-search-wrap input:focus,
#zerno-dash-search:focus,
#linkCompanySearch:focus,
#mailSearch:focus,
#rights-user-filter:focus,
#mmSearch:focus {
  outline: none;
  border-color: var(--poisk-border-focus);
  box-shadow: 0 0 0 3px rgba(147, 197, 253, 0.35);
}

/* Compact toolbar variant — same radius/border/font, tighter padding */
.poisk-compact,
.zl-table-toolbar input[type="search"],
.zl-table-toolbar input[type="search"].poisk-compact {
  --poisk-padding-y: 6px;
  --poisk-padding-x: 10px;
  --poisk-font-size: 13px;
  --poisk-min-height: 32px;
}
