/* Подбор подшипников по размерам — Vue (pixel-perfect из Figma: 360×261). */

.dim-search {
    display: block;
    width: 100%;
    box-sizing: border-box;
    font-family: 'Montserrat', system-ui, sans-serif;
}

/*
 * Подбор по размерам (страница услуги): ≤999.98px — Vue; ≥1000px — PHP #uslugi-bearing-dim-search.
 */
@media (max-width: 999.98px) {
    .uslugi-detail__podbor-vue {
        display: block;
        width: 100%;
        margin-bottom: 14px;
    }

    #uslugi-bearing-dim-search .first-block__form,
    #uslugi-bearing-dim-search .uslugi-detail__podbor-bg {
        display: none !important;
    }
}

@media (min-width: 1000px) {
    .uslugi-detail__podbor-vue {
        display: none !important;
        margin: 0 !important;
        height: 0 !important;
        min-height: 0 !important;
        overflow: hidden !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
}

/* Главная (.industrial): Vue-подбор по размерам вместо PHP first-block__wrap ≤900px */
@media (max-width: 900px) {
    .industrial .first-block .first-block__wrap--bearing-desktop {
        display: none !important;
    }

    .industrial .first-block .first-block__bearing-vue {
        display: block;
        width: 100%;
        min-width: 0;
        box-sizing: border-box;
        grid-column: 1 / -1;
    }
}

@media (min-width: 901px) {
    .industrial .first-block .first-block__bearing-vue {
        display: none !important;
        height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
}

/*
 * Главная: глобальный style.css задаёт .first-block .first-block__red-hover { opacity:0 },
 * .first-block__red-img { visibility:hidden } и при ≤1100px display:none — ломает превью Vue.
 */
.first-block .dim-search .dim-search__red-hover.first-block__red-hover {
    opacity: 1 !important;
}

.first-block .dim-search .dim-search__results-bg .dim-search__red-img.first-block__red-img {
    display: block !important;
    visibility: visible !important;
    position: absolute !important;
    left: 50% !important;
    bottom: 0 !important;
    top: auto !important;
    right: auto !important;
    transform: translateX(-50%) !important;
    width: auto !important;
    height: auto !important;
    max-width: 100% !important;
    max-height: 100% !important;
    margin: 0 !important;
    object-fit: contain !important;
    object-position: center bottom !important;
    z-index: 3 !important;
}

.first-block .dim-search .dim-search__card.is-active {
    border-color: #5479b8 !important;
    box-shadow: 0 0 0 2px rgba(84, 121, 184, 0.35) !important;
}

.first-block .dim-search .dim-search__results-slot {
    contain: layout;
}

/* ——— форма (Frame 35: bg #e5e8ec, radius 10, padding 20/15, gap 20) ——— */
.dim-search__form {
    background: #e5e8ec;
    border-radius: 10px;
    padding: 20px 15px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-sizing: border-box;
}

.dim-search__title {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
}

/* ——— строки (Frame 21: gap 21) ——— */
.dim-search__ranges {
    display: flex;
    flex-direction: column;
    gap: 21px;
}

/* каждая строка: icon gap 15 [inputs frame: gap 5] */
.dim-search__range {
    display: flex;
    align-items: center;
    gap: 15px;
}

.dim-search__icon {
    width: 30px;
    height: 30px;
    flex-shrink: 0;
    display: block;
}

/* ——— инпуты (Frame 15/16: white bg, radius 5, padding 10, h38, Montserrat Medium 12px) ——— */
.dim-search__inputs {
    display: flex;
    gap: 5px;
    flex: 1;
    min-width: 0;
}

.dim-search__input {
    height: 38px;
    padding: 10px;
    border: 0;
    border-radius: 5px;
    background: #ffffff;
    font-family: 'Montserrat', system-ui, sans-serif;
    font-size: 12px;
    font-weight: 500;
    line-height: 18px;
    color: #1a1a1a;
    outline: none;
    box-sizing: border-box;
    -webkit-appearance: none;
    -moz-appearance: textfield;
    appearance: none;
    min-width: 0;
    transition: box-shadow .15s ease;
}

.dim-search__input::-webkit-outer-spin-button,
.dim-search__input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.dim-search__input::placeholder {
    color: rgba(0, 0, 0, 0.604);
    opacity: 1;
    font-weight: 500;
}

.dim-search__input:focus { box-shadow: 0 0 0 2px rgba(84, 121, 184, .35); }

/* Frame 15: flex:1 (≈193px); Frame 16: 84px fixed */
.dim-search__input--from { flex: 1; }
.dim-search__input--to   { flex: 0 0 84px; width: 84px; }

/* ——— кнопка (Link: h45, #5479b8, radius 5, красная полоса 5px снизу) ——— */
.dim-search__btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 45px;
    padding: 0 16px;
    border: 0;
    border-radius: 5px;
    background: #5479b8;
    color: #ffffff;
    font-family: 'Montserrat', system-ui, sans-serif;
    font-size: 16px;
    font-weight: 600;
    line-height: 18px;
    text-decoration: none;
    cursor: pointer;
    overflow: hidden;
    transition: background-color .15s ease, transform .1s ease;
    box-sizing: border-box;
}

.dim-search__btn::after {
    content: '';
    position: absolute;
    left: 0; right: 0; bottom: 0;
    height: 5px;
    background: #e03733;
    border-bottom-left-radius: 5px;
    border-bottom-right-radius: 5px;
}

.dim-search__btn:hover  { background: #6088c7; }
.dim-search__btn:active { transform: translateY(1px); }
.dim-search__btn.is-disabled { pointer-events: none; opacity: .65; }

/* ——— верхний блок: серая панель, белые карточки, светло-серые поля (как референс) ——— */
.dim-search__form--cards {
    --dim-ui-blue: #5479b8;
    --dim-ui-border: #e0e0e0;
    --dim-ui-text: #1a1a1a;
    gap: 10px;
    padding: 15px 15px;
    background: #e5e8ec;
    border: none;
    border-radius: 10px;
    box-shadow: none;
}

.dim-search__form--cards .dim-search__title {
    font-size: 14px;
    font-weight: 700;
    line-height: 1.35;
    color: var(--dim-ui-text);
    margin: 0;
    text-align: left;
}

.dim-search__cards {
    display: flex;
    gap: 10px;
    width: 100%;
    align-items: flex-start;
}

.dim-search__card-col {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.dim-search__card {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px 8px 14px;
    background: #ffffff;
    border-radius: 10px;
    border: 1px solid #e2e6eb;
    box-shadow: none;
    transition: border-color .15s ease, box-shadow .15s ease;
}

.dim-search__card:active {
    background: #ffffff;
}

/* Активная карточка — лёгкая обводка без «неона» */
.dim-search__card.is-active {
    border-color: #c5cdd9;
    box-shadow: 0 0 0 1px rgb(84 121 184);
}



.dim-search__card-icon {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

.dim-search__card-label {
    font-size: 10px;
    font-weight: 600;
    color: #6d7480;
    text-align: center;
    line-height: 1.2;
    max-width: 100%;
}

.dim-search__card-value {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-width: 0;
    min-height: 31px;
    padding: 0 10px 0 10px;
    border: 1px solid #e4e7ec;
    border-radius: 6px;
    background: #eef1f4;
    box-sizing: border-box;
}

.dim-search__card-input {
    flex: 1;
    min-width: 0;
    width: 40%;
    padding: 8px 4px 8px 2px;
    border: 0;
    border-radius: 0;
    background: transparent;
    font-family: 'Montserrat', system-ui, sans-serif;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.2;
    color: var(--dim-ui-text);
    text-align: right;
    outline: none;
    box-sizing: border-box;
    -webkit-appearance: none;
    appearance: none;
}

.dim-search__card-input:focus {
    outline: none;
    box-shadow: none;
}

.dim-search__card-unit {
    font-size: 12px;
    font-weight: 600;
    color: #8b929c;
    flex-shrink: 0;
    padding-left: 2px;
}

.dim-search__card-range-slot {
    flex-shrink: 0;
    min-height: 12px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    width: 100%;
    box-sizing: border-box;
}

.dim-search__card-range {
    display: block;
    font-size: 10px;
    font-weight: 700;
    color: var(--dim-ui-blue);
    text-align: center;
    line-height: 1.25;
    max-width: 100%;
    padding: 0 2px;
    word-break: break-word;
    cursor: default;
}

.dim-search__card-clear {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 22px;
    height: 22px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.06);
    color: #7a8088;
    font-size: 15px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dim-search__tolerance {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-shrink: 0;
    padding: 2px 0 0;
}

.dim-search__tolerance-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.dim-search__tolerance-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--dim-ui-text);
}

.dim-search__tolerance-value {
    font-size: 14px;
    font-weight: 700;
    color: var(--dim-ui-blue);
}

.dim-search__tolerance-range {
    width: 100%;
    height: 28px;
    margin: 0;
    cursor: pointer;
    accent-color: var(--dim-ui-blue);
    background: transparent;
}

.dim-search__tolerance-range::-webkit-slider-runnable-track {
    height: 4px;
    border-radius: 2px;
    box-shadow: inset 0 0 0 1px rgba(74, 85, 104, 0.18);
    background: linear-gradient(
        to right,
        var(--dim-ui-blue) 0%,
        var(--dim-ui-blue) var(--dim-tol-pct, 0%),
        #c4ccd6 var(--dim-tol-pct, 0%),
        #c4ccd6 100%
    );
}

.dim-search__tolerance-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    margin-top: -7px;
    border-radius: 50%;
    background: var(--dim-ui-blue);
    box-shadow: 0 1px 4px rgba(43, 89, 195, 0.35);
    border: 2px solid #fff;
    box-sizing: border-box;
}

.dim-search__tolerance-range::-moz-range-track {
    height: 4px;
    border-radius: 2px;
    background: #c4ccd6;
    box-shadow: inset 0 0 0 1px rgba(74, 85, 104, 0.18);
}

.dim-search__tolerance-range::-moz-range-progress {
    height: 4px;
    border-radius: 2px 0 0 2px;
    background: var(--dim-ui-blue);
}

.dim-search__tolerance-range::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--dim-ui-blue);
    box-shadow: 0 2px 8px rgba(43, 89, 195, 0.35);
    border: 2px solid #fff;
}

/* Фиксированная высота: фон spin + слой с контентом */
.dim-search__results-slot {
    position: relative;
    height: 272px;
    max-height: 272px;
    flex-shrink: 0;
    overflow: hidden;
    border-radius: 12px;
    box-sizing: border-box;
    background: #f0f2f5;
}

.dim-search__results-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
    isolation: isolate;
    background: #fff;
}

.dim-search__results-bg .dim-search__spin-video {
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    z-index: 2;
    display: block;
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    object-position: center bottom;
    margin: 0;
    opacity: 0.42;
}

.dim-search__results-bg .dim-search__red-hover {
    position: absolute;
    inset: 0;
    z-index: 3;
    pointer-events: none;
    opacity: 1;
}

.dim-search__results-bg .dim-search__red-img {
    position: absolute;
    left: 50%;
    bottom: 0;
    top: auto;
    right: auto;
    transform: translateX(-50%);
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    object-position: center bottom;
    display: block;
    opacity: 0;
    transition: opacity 0.18s ease;
}

.dim-search__results-bg .dim-search__red-img.is-dim-pick {
    opacity: 1;
}

/* Обёртка слота: видео + красные слои внутри, не «сзади» отдельным корнем */
.dim-search__results-fg {
    position: relative;
    height: 100%;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    isolation: isolate;
}

/* Пустой слот: фон spin + красные слои без «мутного» стекла поверх */
.dim-search__results-fg.is-empty-nominal .dim-search__spin-video {
    opacity: 0.88;
}

.dim-search__results-fg.is-empty-nominal .dim-search__red-img:not(.is-dim-pick) {
    opacity: 0;
}

.dim-search__results-fg.is-empty-nominal .dim-search__red-img.is-dim-pick {
    opacity: 1;
}

.dim-search__results-content {
    position: relative;
    z-index: 1;
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    background: rgb(229 232 236);
}

.dim-search__results-content--empty {
    background: transparent;
}

.dim-search__slot-fill {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 0;
    padding: 20px 16px;
    text-align: center;
    box-sizing: border-box;
}

.dim-search__results-loading {
    font-size: 14px;
    font-weight: 500;
    color: #8b929c;
}

.dim-search__hint {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 20px 12px 16px;
    background: #ffffff;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.dim-search__hint-icon {
    display: flex;
    opacity: 0.88;
}

.dim-search__hint-text {
    margin: 0;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.4;
    color: #8b929c;
    max-width: 280px;
}

.dim-search__preview {
    margin-top: 2px;
}

.dim-search__preview--in-slot {
    display: flex;
    flex-direction: column;
    flex: 1 1 0;
    margin: 0;
    min-height: 0;
    max-height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box;
    scrollbar-width: thin;
    scrollbar-gutter: stable;
}

.dim-search__preview--in-slot::-webkit-scrollbar {
    width: 4px;
}

.dim-search__preview--in-slot::-webkit-scrollbar-thumb {
    background: #cfd4db;
    border-radius: 4px;
}

.dim-search__preview-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.dim-search__preview-item {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    padding: 10px 10px;
    background: #ffffff;
    text-decoration: none;
    color: inherit;
    border: none;
    border-bottom: 1px solid #e8e8e8;
    box-shadow: none;
    transition: background .12s ease;
    border-radius: 8px;
}

.dim-search__preview-item:first-child {
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}

.dim-search__preview-item:last-child {
    border-bottom: none;
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
}

.dim-search__preview-item:active {
    background: #f7f8fa;
}

.dim-search__preview-img-wrap {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    border-radius: 8px;
    overflow: hidden;
    background: #f4f5f7;
    border: 1px solid #e8e8e8;
    box-sizing: border-box;
}

.dim-search__preview-img-wrap--empty {
    background: linear-gradient(135deg, #f0f1f3 0%, #e8eaed 100%);
}

.dim-search__preview-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center center;
    display: block;
}

.dim-search__preview-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dim-search__preview-name {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.dim-search__preview-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 8px;
    margin-top: 2px;
    line-height: 1.35;
}

.dim-search__preview-brand {
    font-size: 11px;
    font-weight: 600;
    color: #6b7280;
    flex-shrink: 0;
    max-width: 100%;
}

.dim-search__preview-meta-dot {
    font-size: 11px;
    font-weight: 600;
    color: #9ca3af;
    user-select: none;
}

.dim-search__preview-dims {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 10px;
}

.dim-search__preview-dim {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.dim-search__preview-dim-icon {
    width: 14px;
    height: 14px;
    object-fit: contain;
    flex-shrink: 0;
    display: block;
}

.dim-search__preview-dim-val {
    font-size: 11px;
    font-weight: 700;
    color: #4b5563;
}

.dim-search__preview-aside {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
    gap: 6px;
    flex-shrink: 0;
    min-width: 72px;
}

.dim-search__preview-price {
    font-size: 16px;
    font-weight: 700;
    color: #2b59c3;
    line-height: 1.2;
    white-space: nowrap;
}

.dim-search__preview-chevron {
    display: block;
    width: 8px;
    height: 8px;
    border-right: 2px solid #c4c8d0;
    border-bottom: 2px solid #c4c8d0;
    transform: rotate(-45deg);
    margin-right: 2px;
}

.dim-search__slot-fill.dim-search__preview-empty {
    flex: 1 1 0;
    align-self: stretch;
    width: 100%;
    min-width: 0;
    min-height: 0;
    max-width: none;
    margin: 0;
    padding: 24px 16px;
    box-sizing: border-box;
    background: #ffffff;
    border-radius: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    text-align: center;
}

.dim-search__preview-empty-title {
    font-size: 14px;
    font-weight: 700;
    line-height: 1.35;
    color: #1a1a1a;
    max-width: 100%;
}

.dim-search__preview-empty-hint {
    font-size: 12px;
    font-weight: 500;
    line-height: 1.45;
    color: #6d7480;
    max-width: 320px;
}

.dim-search__form--cards .dim-search__btn {
    flex-shrink: 0;
    margin-top: 2px;
    height: 50px;
    border-radius: 8px;
    background: #2b59c3;
    font-size: 16px;
    font-weight: 700;
}

.dim-search__form--cards .dim-search__btn:hover {
    background: #244aa8;
}

.dim-search__form--cards .dim-search__btn::after {
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
    height: 4px;
}

:root {
    --dim-sheet-vh: 100dvh;
    --dim-drag-y: 0px;
    --dim-keyboard-inset: 0px;
}

body[data-scroll-locked="1"] {
    overflow: hidden !important;
    overscroll-behavior: none;
}

.dim-bs-root {
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
    height: var(--dim-sheet-vh);
    z-index: 2147483000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity .18s ease;
    contain: layout style paint;
}

.dim-bs-root[data-state="open"] {
    opacity: 1;
    pointer-events: auto;
}

.dim-bs-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .74);
    opacity: 0;
    transition: opacity .18s ease;
    touch-action: none;
}

.dim-bs-root[data-state="open"] .dim-bs-overlay {
    opacity: 1;
}

.dim-bs-dialog {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: none;
    max-height: calc(var(--dim-sheet-vh) - var(--dim-keyboard-inset) - 8px);
    min-height: 0;
    display: flex;
    flex-direction: column;
    background: #ffffff;
    color: #1a1a1a;
    border-radius: 4px 4px 0 0;
    box-shadow: none;
    transform: translate3d(0, 105%, 0);
    transition: transform .265s cubic-bezier(.2, .8, .2, 1);
    will-change: transform;
    outline: none;
    overflow: hidden;
    margin-bottom: var(--dim-keyboard-inset);
}

.dim-bs-root[data-state="open"] .dim-bs-dialog {
    transform: translate3d(0, var(--dim-drag-y), 0);
}

.dim-bs-root.is-dragging .dim-bs-dialog,
.dim-bs-root.is-keyboard .dim-bs-dialog,
.dim-bs-root.is-keyboard .dim-bs-overlay {
    transition: none;
}

.dim-bs-grip-zone {
    flex: 0 0 auto;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    touch-action: none;
    cursor: grab;
}

.dim-bs-grip {
    width: 45px;
    height: 5px;
    border-radius: 999px;
    background: #777777;
}

.dim-bs-head {
    flex: 0 0 auto;
    min-height: 29px;
    padding: 0 13px 9px 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.dim-bs-title {
    margin: 0;
    font-size: 15px;
    line-height: 1.2;
    font-weight: 500;
    color: #1a1a1a;
    letter-spacing: normal;
}

.dim-bs-close {
    width: 28px;
    height: 28px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #000000;
    font-size: 38px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.dim-bs-content {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    padding: 0 18px max(21px, env(safe-area-inset-bottom));
}

.dim-search-popup {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.dim-search-popup__fields {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.dim-search-popup__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 107px;
    gap: 9px;
}

.dim-search-popup__field {
    position: relative;
    display: block;
    height: 36px;
    min-width: 0;
    background: #dfe5ee;
    border-radius: 4px;
    overflow: hidden;
}

.dim-search-popup__label {
    position: absolute;
    left: 12px;
    right: 28px;
    top: 50%;
    transform: translateY(-50%);
    color: #6d7480;
    font-size: 13px;
    font-weight: 500;
    line-height: 16px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    pointer-events: none;
}

.dim-search-popup__field.is-filled .dim-search-popup__label {
    top: 4px;
    transform: none;
    font-size: 12px;
    line-height: 12px;
}

.dim-search-popup__input {
    width: 100%;
    height: 100%;
    padding: 14px 30px 2px 12px;
    border: 0;
    outline: 0;
    background: transparent;
    color: #111111;
    font-family: 'Montserrat', system-ui, sans-serif;
    font-size: 14px;
    font-weight: 500;
    line-height: 18px;
    box-sizing: border-box;
    -webkit-appearance: none;
    -moz-appearance: textfield;
    appearance: none;
}

.dim-search-popup__input::-webkit-outer-spin-button,
.dim-search-popup__input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.dim-search-popup__clear {
    position: absolute;
    right: 9px;
    top: 50%;
    width: 14px;
    height: 14px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: #8f9499;
    color: #ffffff;
    font-size: 13px;
    line-height: 14px;
    font-family: Arial, sans-serif;
    cursor: pointer;
    transform: translateY(-50%);
}

.dim-search-popup__actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 176px;
    align-items: center;
    height: 51px;
    padding: 4px;
    border-radius: 26px;
    background: #ef3330;
    box-sizing: border-box;
}

.dim-search-popup__found {
    color: #ffffff;
    font-size: 15px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
}

.dim-search-popup__submit {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 43px;
    border-radius: 23px;
    background: #5d82bf;
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
    line-height: 18px;
    text-decoration: none;
    box-shadow: inset 0 0 0 2px #ffffff;
}

.dim-search-popup__actions.is-disabled {
    opacity: .65;
}

.dim-search-popup__button {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 36px;
    border-radius: 4px;
    background: #5479b8;
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
    line-height: 18px;
    text-decoration: none;
    overflow: hidden;
}

.dim-search-popup__button::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 4px;
    background: #e03733;
}

.dim-search-popup__button.is-disabled {
    opacity: .65;
    pointer-events: none;
}

/* Та же карточка, что инлайн (Figma), внутри шторки */
.dim-search__form--sheet {
    background: #e5e8ec;
    border-radius: 10px;
    padding: 20px 15px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-sizing: border-box;
    margin: 0;
}

/* iOS: в шторке 16px, чтобы не зумило */
.dim-search__form--sheet .dim-search__input {
    font-size: 16px;
}

.dim-bs-footer {
    flex: 0 0 auto;
    padding: 14px 16px max(16px, env(safe-area-inset-bottom));
    background: linear-gradient(to top, #ffffff 82%, rgba(255, 255, 255, 0));
}

.dim-bs-primary {
    width: 100%;
    height: 50px;
    border: 0;
    border-radius: 10px;
    background: #1a1a1a;
    color: #fff;
    font-weight: 780;
    font-size: 16px;
    cursor: pointer;
}

.dim-bs-primary.is-disabled {
    opacity: .65;
    pointer-events: none;
}

/* ============================== BOTTOM SHEET (drom-style, только мобиле) ============================== */
.dim-search-sheet {
    position: fixed;
    inset: 0;
    z-index: 6000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.dim-search-sheet__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .5);
}

.dim-search-sheet__card {
    position: relative;
    width: 100%;
    background: #fff;
    border-top-left-radius: 16px;
    border-top-right-radius: 16px;
    padding-bottom: env(safe-area-inset-bottom, 0px);
    box-shadow: 0 -4px 24px rgba(0, 0, 0, .18);
    overflow: hidden;
}

.dim-search-sheet__drag {
    width: 36px;
    height: 4px;
    border-radius: 2px;
    background: #d0d4da;
    margin: 10px auto 0;
}

.dim-search-sheet__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px 10px;
}

.dim-search-sheet__title {
    font-size: 17px;
    font-weight: 600;
    color: #1a1a1a;
    font-family: 'Montserrat', system-ui, sans-serif;
}

.dim-search-sheet__close {
    width: 32px;
    height: 32px;
    border: 0;
    background: transparent;
    color: #888;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.dim-search-sheet__body {
    padding: 8px 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.dim-search-sheet__row {
    display: flex;
    gap: 10px;
}

.dim-search-sheet__input {
    flex: 1;
    height: 46px;
    padding: 0 14px;
    border: 1.5px solid #e0e3ea;
    border-radius: 8px;
    background: #f5f6f8;
    font-family: 'Montserrat', system-ui, sans-serif;
    font-size: 16px;
    font-weight: 400;
    color: #1a1a1a;
    outline: none;
    box-sizing: border-box;
    -webkit-appearance: none;
    -moz-appearance: textfield;
    appearance: none;
    transition: border-color .15s ease;
}

.dim-search-sheet__input::-webkit-outer-spin-button,
.dim-search-sheet__input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.dim-search-sheet__input::placeholder { color: #9da4b0; }

.dim-search-sheet__input:focus {
    border-color: #5479b8;
    background: #fff;
}

.dim-search-sheet__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 50px;
    border: 0;
    border-radius: 8px;
    background: #5479b8;
    color: #fff;
    font-family: 'Montserrat', system-ui, sans-serif;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    box-sizing: border-box;
    transition: background-color .15s ease;
}

.dim-search-sheet__btn:hover { background: #6088c7; }
.dim-search-sheet__btn.is-disabled { opacity: .65; pointer-events: none; }

/* ============================== BOTTOM SHEET (мобиле ≤900px) ============================== */
.dim-search-sheet-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 5999;
    opacity: 0;
    transition: opacity .18s ease;
}

.dim-search-sheet-overlay.is-open { opacity: 1; }

.dim-search-sheet {
    position: fixed;
    top: auto;
    left: 0; right: 0; bottom: 0;
    z-index: 6000;
    display: block;
    background: #fff;
    border-radius: 18px 18px 0 0;
    padding: 0 0 calc(20px + env(safe-area-inset-bottom));
    box-shadow: 0 -8px 24px rgba(0, 0, 0, .25);
    max-height: 88vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    will-change: transform;
    transform: translateY(100%);
    transition: transform .32s cubic-bezier(0.32, 0.72, 0, 1);
}

.dim-search-sheet.is-open { transform: translateY(0); }
.dim-search-sheet.is-dragging { transition: none; }

.dim-search-sheet__handle-area {
    padding: 10px 0 4px;
    cursor: grab;
    touch-action: none;
    text-align: center;
}

.dim-search-sheet__drag {
    display: inline-block;
    width: 40px;
    height: 4px;
    border-radius: 2px;
    background: #d0d4da;
}

.dim-search-sheet__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 20px 12px;
}

.dim-search-sheet__title {
    font-size: 17px;
    font-weight: 600;
    color: #1a1a1a;
    font-family: 'Montserrat', system-ui, sans-serif;
}

.dim-search-sheet__close {
    background: none;
    border: none;
    color: #8a8a8e;
    font-size: 28px;
    line-height: 1;
    padding: 4px 6px;
    cursor: pointer;
    font-family: inherit;
}

.dim-search-sheet__body {
    padding: 4px 20px 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.dim-search-sheet__fields {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.dim-search-sheet__field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.dim-search-sheet__row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.dim-search-sheet__label {
    color: #1a1a1a;
    font-family: 'Montserrat', system-ui, sans-serif;
    font-size: 13px;
    font-weight: 600;
    line-height: 18px;
}

.dim-bs-content .dim-search-sheet__label {
    color: rgba(255, 255, 255, .86);
}

/* font-size: 16px обязателен — иначе iOS зумит при фокусе */
.dim-search-sheet__input {
    background: #f5f6f8;
    border: 1px solid transparent;
    border-radius: 10px;
    padding: 14px 16px;
    color: #1a1a1a;
    font-size: 16px;
    font-family: 'Montserrat', system-ui, sans-serif;
    font-weight: 400;
    width: 100%;
    box-sizing: border-box;
    outline: none;
    transition: border-color .15s, background .15s;
    -webkit-appearance: none;
    appearance: none;
    -moz-appearance: textfield;
}

.dim-search-sheet__input::-webkit-outer-spin-button,
.dim-search-sheet__input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.dim-search-sheet__input::placeholder { color: #9da4b0; }

.dim-search-sheet__input:focus {
    border-color: #5479b8;
    background: #fff;
}

.dim-search-sheet__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 52px;
    border: 0;
    border-radius: 10px;
    background: #5479b8;
    color: #fff;
    font-family: 'Montserrat', system-ui, sans-serif;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    box-sizing: border-box;
    transition: background-color .15s ease;
    margin-bottom: 4px;
}

.dim-search-sheet__btn:hover { background: #6088c7; }
.dim-search-sheet__btn:active { transform: scale(0.99); }
.dim-search-sheet__btn.is-disabled { opacity: .65; pointer-events: none; }


.first-block__form-vue { display: none; }

@media (max-width: 900px) {
    .dim-search__form--mobile {
        -webkit-tap-highlight-color: transparent;
    }

    .first-block__form-vue.first-block__form-vue--mobile {
        display: block;
        margin: 0 0 14px;
    }
    #uslugi-bearing-dim-search .first-block .modal__overlay {
        display: none !important;
    }
}

@media (max-width: 768px) {
    .dim-search__form--cards .dim-search__title {
        font-size: 18px;
        font-weight: 600;
        line-height: 1.3;
        text-align: center;
    }
}
