/* Чёрный список VKService. Стили изолированы от остальных страниц. */
.bl-v2 {
    --bl-primary: var(--color-primary, #6756c8);
    --bl-primary-hover: var(--color-primary-hover, #5949b8);
    --bl-text: var(--color-text-primary, #15182b);
    --bl-muted: var(--color-text-secondary, #000);
    --bl-border: var(--color-border, #e2e5ee);
    width: 100%;
    min-width: 0;
    color: var(--bl-text);
    font-family: var(--font-family-base, "Montserrat", Arial, sans-serif);
}

.bl-v2 *,
.bl-v2 *::before,
.bl-v2 *::after {
    box-sizing: border-box;
}

.bl-v2__hero {
    position: relative;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    min-width: 0;
    margin-bottom: 18px;
    padding: 26px 30px;
    overflow: hidden;
    border-radius: 18px;
    background: linear-gradient(115deg, #5143a7 0%, #6554c4 60%, #8971d5 100%);
    color: #fff;
    box-shadow: 0 12px 28px rgba(69, 55, 145, .12);
}

.bl-v2__hero::before,
.bl-v2__hero::after {
    content: "";
    position: absolute;
    width: 250px;
    height: 250px;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 50%;
    pointer-events: none;
}

.bl-v2__hero::before {
    top: -165px;
    right: -28px;
}

.bl-v2__hero::after {
    right: 80px;
    bottom: -215px;
    background: rgba(255, 255, 255, .045);
}

.bl-v2__hero-content,
.bl-v2__back {
    position: relative;
    z-index: 1;
}

.bl-v2__hero-content {
    min-width: 0;
    max-width: 830px;
}

.bl-v2__hero-label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 11px;
    border: 1px solid rgba(255, 255, 255, .17);
    border-radius: 999px;
    background: rgba(255, 255, 255, .12);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
}

.bl-v2__hero h1 {
    margin: 13px 0 5px;
    color: #fff;
    font-size: clamp(23px, 2.35vw, 34px);
    line-height: 1.2;
    font-weight: 800;
    letter-spacing: -.025em;
}

.bl-v2__hero p {
    max-width: 740px;
    margin: 0;
    color: rgba(255, 255, 255, .88);
    font-size: 13px;
    line-height: 1.65;
}

.bl-v2__hero-profile {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    max-width: 100%;
    margin-top: 17px;
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    overflow-wrap: anywhere;
}

.bl-v2__back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    flex: 0 0 auto;
    min-height: 41px;
    padding: 9px 14px;
    border: 1px solid rgba(255, 255, 255, .33);
    border-radius: 10px;
    background: rgba(255, 255, 255, .10);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    transition: background .18s ease;
}

.bl-v2__back:hover,
.bl-v2__back:focus-visible {
    background: rgba(255, 255, 255, .20);
    color: #fff;
}

.bl-v2__add-card,
.bl-v2__list-card {
    min-width: 0;
    margin-bottom: 16px;
    padding: 20px;
    border: 1px solid var(--bl-border);
    border-radius: 15px;
    background: #fff;
    box-shadow: 0 5px 18px rgba(30, 33, 55, .045);
}

.bl-v2__section-heading,
.bl-v2__section-title,
.bl-v2__search-row,
.bl-v2__item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.bl-v2__section-heading {
    justify-content: space-between;
    margin-bottom: 17px;
}

.bl-v2__section-title {
    min-width: 0;
}

.bl-v2__section-icon {
    display: grid;
    place-items: center;
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    border-radius: 11px;
    background: #f0ecff;
    color: var(--bl-primary);
    font-size: 18px;
}

.bl-v2__section-heading h2 {
    margin: 0 0 4px;
    color: var(--bl-text);
    font-size: 15px;
    line-height: 1.3;
    font-weight: 700;
}

.bl-v2__section-heading p {
    margin: 0;
    color: var(--bl-muted);
    font-size: 12px;
    line-height: 1.5;
}

.bl-v2__add-form {
    min-width: 0;
}

.bl-v2__add-form .field-processingblacklist-profile_id,
.bl-v2__add-form .field-processingblacklist-cron_task_type,
.bl-v2__add-form .field-processingblacklist-vk_id,
.bl-v2__add-form .field-processingblacklist-vk_profile_info {
    margin: 0;
}

.bl-v2__search-row {
    align-items: flex-end;
    width: 100%;
    max-width: 950px;
}

.bl-v2__search-box {
    position: relative;
    flex: 1 1 auto;
    min-width: 0;
}

.bl-v2__label {
    display: block;
    margin-bottom: 7px;
    color: var(--bl-text);
    font-size: 12px;
    font-weight: 600;
}

.bl-v2__search-control {
    position: relative;
    min-width: 0;
}

.bl-v2__search-control>.bi,
.bl-v2__filter-field>.bi {
    position: absolute;
    z-index: 1;
    top: 50%;
    left: 14px;
    transform: translateY(-50%);
    color: #9488ce;
    font-size: 16px;
    pointer-events: none;
}

.bl-v2__search-input,
.bl-v2__filter-form .form-control {
    width: 100%;
    min-width: 0;
    min-height: 44px;
    padding: 10px 13px 10px 42px;
    border: 1px solid #dce0eb;
    border-radius: 9px;
    background: #fff;
    color: var(--bl-text);
    font-family: inherit;
    font-size: 13px;
    line-height: 1.45;
}

.bl-v2__search-input:focus,
.bl-v2__filter-form .form-control:focus {
    outline: none;
    border-color: var(--bl-primary);
    box-shadow: 0 0 0 3px rgba(103, 86, 200, .12);
}

.bl-v2__submit,
.bl-v2__filter-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex: 0 0 auto;
    min-height: 44px;
    padding: 10px 19px;
    border: 1px solid var(--bl-primary);
    border-radius: 9px;
    background: var(--bl-primary);
    color: #fff;
    font-family: inherit;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.3;
    cursor: pointer;
    transition: background .18s ease;
}

.bl-v2__submit:hover,
.bl-v2__filter-submit:hover {
    border-color: var(--bl-primary-hover);
    background: var(--bl-primary-hover);
}

.bl-v2__submit:disabled {
    border-color: #dadbe4;
    background: #dfe1eb;
    color: #9298a8;
    cursor: not-allowed;
}

.bl-v2__dropdown {
    position: absolute;
    z-index: 1010;
    top: calc(100% + 5px);
    left: 0;
    width: 100%;
    max-height: 270px;
    padding: 5px;
    overflow-x: hidden;
    overflow-y: auto;
    border: 1px solid #ded9ef;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 12px 28px rgba(31, 35, 54, .15);
}

.bl-v2__dropdown[hidden],
.bl-v2__chosen[hidden] {
    display: none !important;
}

.bl-v2__option {
    display: block;
    width: 100%;
    min-width: 0;
    padding: 10px;
    border: 0;
    border-radius: 7px;
    background: transparent;
    color: var(--bl-text);
    font-family: inherit;
    font-size: 12px;
    line-height: 1.55;
    text-align: left;
    overflow-wrap: anywhere;
    cursor: pointer;
}

.bl-v2__option:hover,
.bl-v2__option:focus-visible {
    outline: none;
    background: #f2efff;
}

.bl-v2__dropdown-empty {
    padding: 13px;
    color: var(--bl-muted);
    font-size: 12px;
}

.bl-v2__chosen {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    max-width: 950px;
    margin-top: 13px;
    padding: 10px 12px;
    border: 1px solid #e3def8;
    border-radius: 9px;
    background: #f8f6ff;
    font-size: 12px;
    overflow-wrap: anywhere;
}

.bl-v2__chosen>.bi {
    color: var(--bl-primary);
}

.bl-v2__chosen-label {
    color: var(--bl-muted);
}

.bl-v2__chosen strong {
    flex: 1 1 auto;
    min-width: 0;
}

.bl-v2__clear {
    padding: 5px;
    border: 0;
    background: transparent;
    color: var(--bl-primary);
    font-family: inherit;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}

.bl-v2__form-footer {
    display: flex;
    align-items: center;
    gap: 7px 15px;
    flex-wrap: wrap;
    margin-top: 11px;
}

.bl-v2__help {
    color: var(--bl-muted);
    font-size: 11px;
    line-height: 1.5;
}

.bl-v2__help .bi {
    color: var(--bl-primary);
}

.bl-v2__feedback {
    color: #248845;
    font-size: 12px;
    line-height: 1.5;
}

.bl-v2__feedback.is-error {
    color: #cf3545;
}

.bl-v2__count {
    flex: 0 0 auto;
    padding: 7px 10px;
    border: 1px solid #e4defb;
    border-radius: 8px;
    background: #f4f1ff;
    color: var(--bl-primary);
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.bl-v2__filter-form {
    display: flex;
    align-items: center;
    gap: 9px;
    min-width: 0;
    margin-bottom: 16px;
}

.bl-v2__filter-field {
    position: relative;
    flex: 1 1 auto;
    min-width: 0;
}

.bl-v2__filter-input-wrapper {
    margin: 0;
}

.bl-v2__filter-submit {
    min-height: 42px;
    padding-inline: 17px;
}

.bl-v2__filter-reset {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    min-height: 42px;
    padding: 10px 14px;
    border: 1px solid #ded9ef;
    border-radius: 9px;
    background: #fff;
    color: var(--bl-primary);
    font-size: 12px;
    font-weight: 700;
    line-height: 1.3;
    text-decoration: none;
}

.bl-v2__filter-reset:hover {
    background: #f6f3ff;
    color: var(--bl-primary-hover);
}

.bl-v2__items {
    display: grid;
    gap: 8px;
}

.bl-v2__item {
    min-width: 0;
    padding: 12px 14px;
    border: 1px solid #e7e9f0;
    border-radius: 11px;
    background: #fff;
    transition: border-color .18s ease, background .18s ease;
}

.bl-v2__item:hover {
    border-color: #d9d3f5;
    background: #fdfcff;
}

.bl-v2__avatar {
    display: grid;
    place-items: center;
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    border-radius: 11px;
    background: #f0ecff;
    color: var(--bl-primary);
    font-size: 18px;
}

.bl-v2__item-info {
    flex: 1 1 auto;
    min-width: 0;
}

.bl-v2__item-info strong {
    display: block;
    color: var(--bl-text);
    font-size: 12px;
    font-weight: 600;
    line-height: 1.55;
    overflow-wrap: anywhere;
}

.bl-v2__vk-link {
    display: inline-block;
    margin-top: 3px;
    color: var(--bl-primary);
    font-size: 11px;
    font-weight: 500;
    text-decoration: none;
    overflow-wrap: anywhere;
}

.bl-v2__vk-link:hover {
    text-decoration: underline;
}

.bl-v2__delete-form {
    flex: 0 0 auto;
    margin: 0;
}

.bl-v2__delete {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 38px;
    padding: 8px 12px;
    border: 1px solid #f1d7d9;
    border-radius: 8px;
    background: #fff;
    color: #c54750;
    font-family: inherit;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
}

.bl-v2__delete:hover {
    background: #fff1f2;
    border-color: #eabdc1;
}

.bl-v2__delete:disabled {
    opacity: .6;
    cursor: wait;
}

.bl-v2__empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 35px 12px;
    border: 1px dashed #e0dcf2;
    border-radius: 11px;
    background: #fcfbff;
    color: var(--bl-muted);
    font-size: 12px;
    text-align: center;
}

.bl-v2__empty-icon {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    margin-bottom: 3px;
    border-radius: 12px;
    background: #f0ecff;
    color: var(--bl-primary);
    font-size: 19px;
}

.bl-v2__empty strong {
    color: var(--bl-text);
    font-size: 13px;
}

.bl-v2__pagination {
    justify-content: center;
    flex-wrap: wrap;
    gap: 4px;
    margin: 18px 0 0;
}

.bl-v2__pagination .page-link {
    border-radius: 7px;
    color: var(--bl-primary);
    font-size: 12px;
}

.bl-v2__pagination .active .page-link {
    border-color: var(--bl-primary);
    background: var(--bl-primary);
    color: #fff;
}

@media (max-width: 767px) {
    .bl-v2__hero {
        flex-direction: column;
        gap: 15px;
        padding: 20px 18px;
        border-radius: 14px;
    }

    .bl-v2__hero h1 {
        font-size: 24px;
    }

    .bl-v2__back {
        min-height: 40px;
    }

    .bl-v2__add-card,
    .bl-v2__list-card {
        padding: 15px;
        border-radius: 12px;
    }

    .bl-v2__section-heading {
        align-items: flex-start;
    }

    .bl-v2__section-heading h2 {
        font-size: 14px;
    }

    .bl-v2__section-heading p {
        font-size: 11px;
    }

    .bl-v2__search-row {
        align-items: stretch;
        flex-direction: column;
    }

    .bl-v2__submit {
        width: 100%;
    }

    .bl-v2__filter-form {
        flex-wrap: wrap;
    }

    .bl-v2__filter-field {
        flex-basis: 100%;
    }

    .bl-v2__filter-submit,
    .bl-v2__filter-reset {
        flex: 1 1 auto;
    }
}

@media (max-width: 480px) {
    .bl-v2__hero {
        padding: 18px 15px;
    }

    .bl-v2__hero h1 {
        font-size: 22px;
    }

    .bl-v2__hero-profile {
        align-items: flex-start;
    }

    .bl-v2__section-icon {
        flex-basis: 36px;
        width: 36px;
        height: 36px;
        font-size: 16px;
    }

    .bl-v2__list-heading {
        flex-wrap: wrap;
    }

    .bl-v2__item {
        display: grid;
        grid-template-columns: 36px minmax(0, 1fr);
        gap: 10px;
        padding: 11px;
    }

    .bl-v2__avatar {
        grid-column: 1;
        grid-row: 1;
        width: 36px;
        height: 36px;
    }

    .bl-v2__item-info {
        grid-column: 2;
        grid-row: 1;
    }

    .bl-v2__delete-form {
        grid-column: 1 / -1;
        grid-row: 2;
        width: 100%;
        margin: 0;
    }

    .bl-v2__delete {
        width: 100%;
        min-height: 40px;
    }
}

