.selection-toolbar-actions,
.selection-picker__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.favorites-page__toolbar .selection-primary,
.selection-picker .selection-primary {
    background: #1d3d6e;
    border-color: #1d3d6e;
    color: white;
}

.selection-modal-open { overflow: hidden; }
.selection-picker:not([open]),
.selection-picker [hidden],
.selection-public-tools [hidden] { display: none !important; }

.selection-picker {
    position: fixed;
    inset: 0;
    box-sizing: border-box;
    width: min(580px, calc(100% - 24px));
    max-height: calc(100vh - 32px);
    max-height: calc(100dvh - 32px);
    margin: auto;
    padding: 0;
    overflow: auto;
    overscroll-behavior: contain;
    border: 1px solid #dbe5f0;
    border-radius: 18px;
    background: #fff;
    color: #1d3d6e;
    box-shadow: 0 18px 60px rgba(15,43,79,.22);
    font: inherit;
}

.selection-picker::backdrop { background: rgba(15,31,56,.58); }
.selection-picker__inner { padding: clamp(18px, 4vw, 30px); }
.selection-picker__header,
.selection-picker__counter {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.selection-picker__header h2 { margin: 0; color: #17345f; font-family: inherit; font-size: clamp(22px,4vw,30px); font-weight: 700; line-height: 1.2; }
.selection-picker button,
.selection-picker__actions a {
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 8px 14px;
    border: 1px solid #cedce9;
    border-radius: 9px;
    background: white;
    color: #1d3d6e;
    font: inherit;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}
.selection-picker button:disabled { opacity: .5; cursor: default; }
.selection-picker button:focus-visible,
.selection-picker a:focus-visible,
.selection-picker input:focus-visible { outline: 2px solid #0665d3; outline-offset: 2px; }
.selection-picker .selection-picker__close { width: 42px; padding: 0; font-size: 24px; }
.selection-picker fieldset { min-width: 0; margin: 16px 0; padding: 0; border: 0; }
.selection-picker__counter { margin-bottom: 6px; font-size: 14px; }
.selection-picker__counter button { padding: 4px 8px; border: 0; font-size: 13px; }
.selection-picker__list {
    max-height: min(37vh, 330px);
    overflow: auto;
    overscroll-behavior: contain;
    border-block: 1px solid #dce5ed;
}
.selection-picker__row { display: flex; align-items: center; gap: 12px; min-height: 46px; padding: 6px 4px; cursor: pointer; }
.selection-picker__row + .selection-picker__row { border-top: 1px solid #edf1f5; }
.selection-picker__row input { flex: none; width: 18px; height: 18px; margin: 0; accent-color: #1d3d6e; }
.selection-picker__row strong, .selection-picker__row small { display: block; }
.selection-picker__row strong { font-size: 14px; line-height: 1.35; }
.selection-picker__row small { margin-top: 2px; color: #526681; font-size: 12px; }
.selection-picker__row input:disabled + span { opacity: .6; }
.selection-picker__title,
.selection-result label { display: block; font-size: 14px; font-weight: 600; }
.selection-picker__title { margin-top: 16px; }
.selection-picker__title span { font-size: 12px; font-weight: 400; }
.selection-picker input[type="text"],
.selection-picker input[type="url"],
.selection-public-tools input {
    box-sizing: border-box;
    width: 100%;
    min-height: 42px;
    margin: 5px 0 0;
    padding: 8px 10px;
    border: 1px solid #bfcedb;
    border-radius: 8px;
    background: white;
    color: #17345f;
    font: inherit;
    font-size: 16px;
}
.selection-result { margin-top: 14px; padding-top: 14px; border-top: 1px solid #dce5ed; }
.selection-result .selection-picker__actions { margin-top: 8px; }
.selection-message { display: block; margin: 8px 0 0; color: #405775; font-size: 13px; }
.selection-message:empty { display: none; }
.selection-message[role="alert"] { color: #93351f; }
.selection-file { display: inline-block; margin-top: 6px; color: #154b94; font-size: 14px; text-decoration: underline; }
.selection-public-tools { min-width: 0; max-width: 100%; }
.selection-public-tools .client-selection__hero-actions { flex-wrap: wrap; }
.selection-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (max-width: 600px) {
    .selection-toolbar-actions { width: 100%; }
    .selection-toolbar-actions > button { flex: 1 1 130px; }
    .selection-picker__actions > * { flex: 1 1 auto; }
}
