/* The form aligns children to the start, so the row would otherwise shrink to its content. */
[data-jobvite-openings] .filters {
    width: 100%;
    align-items: start;
}

@media screen and (min-width: 992px) {
    [data-jobvite-openings] .filters {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
        gap: 16px;
    }

    /* Let each filter participate in the same grid so every control is the same width. */
    [data-jobvite-openings] .filters .select-block {
        display: contents;
    }

    [data-jobvite-openings] .filters .select {
        min-width: 0;
        margin-right: 0;
    }
}

[data-jobvite-openings] .filters .select .select2-container,
[data-jobvite-openings] .filters .select select:not(.select2-hidden-accessible):not(.jv-category-select),
[data-jobvite-openings] .filters .input input {
    width: 100% !important;
    min-width: 0;
    max-width: 100%;
    min-height: 50px;
    margin: 0;
    font-size: 16px;
    line-height: 24px;
    vertical-align: middle;
}

/* The native multi-select is a scrolling list. Keep it out of view until Select2 replaces the placeholder face. */
[data-jobvite-openings] .filters .select:has(> .jv-category-select) {
    position: relative;
}

[data-jobvite-openings] select.jv-category-select {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    margin: -1px !important;
    padding: 0 !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    clip-path: inset(50%) !important;
    border: 0 !important;
    white-space: nowrap !important;
}

[data-jobvite-openings] .jv-category-face {
    display: flex;
    align-items: center;
    box-sizing: border-box;
    width: 100%;
    height: 50px;
    padding: 8px 40px 8px 12px;
    border: 1px solid #646569;
    background-color: #fff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9' fill='none'%3E%3Cpath d='M1 1L7 7L13 1' stroke='%23646569' stroke-width='2'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 14px 9px;
    font-size: 16px;
    font-weight: 400;
    line-height: 24px;
}

[data-jobvite-openings] .jv-category-select.select2-hidden-accessible ~ .jv-category-face,
[data-jobvite-openings] .jv-category-select.jv-category-native ~ .jv-category-face {
    display: none !important;
}

[data-jobvite-openings] select.jv-category-select.jv-category-native {
    position: static !important;
    width: 100% !important;
    height: auto !important;
    min-height: 50px !important;
    margin: 0 !important;
    overflow: auto !important;
    clip: auto !important;
    clip-path: none !important;
    white-space: normal !important;
}

[data-jobvite-openings] .jv-submit {
    display: none !important;
}

[data-jobvite-openings] .select2-container--default .select2-selection--multiple {
    display: flex;
    align-items: center;
    min-height: 50px;
    border: 1px solid #646569;
    border-radius: 0;
    background-color: #fff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9' fill='none'%3E%3Cpath d='M1 1L7 7L13 1' stroke='%23646569' stroke-width='2'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 14px 9px;
    padding: 8px 40px 8px 12px;
    cursor: pointer;
}

[data-jobvite-openings] .select2-container--default.select2-container--focus .select2-selection--multiple {
    border-color: #646569;
    outline: none;
}

[data-jobvite-openings] .select2-container--default .select2-selection--multiple .select2-selection__rendered {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    width: 100%;
    margin: 0;
    padding: 0;
}

[data-jobvite-openings] .select2-container--default .select2-selection--multiple .select2-selection__choice {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    float: none;
    position: relative;
    max-width: 100%;
    height: 26px;
    margin: 0;
    padding: 0 8px 0 4px;
    border: 0;
    border-radius: 0;
    background: #E4F2F8;
    color: #1d2327;
    font-size: 16px;
    line-height: 24px;
    white-space: nowrap;
}

/* Theme Select2 CSS pulls the remove control out of flow and covers the label. */
[data-jobvite-openings] .select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
    position: static;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    color: #646569;
    font-size: 16px;
    font-weight: 600;
    line-height: 16px;
    text-align: center;
}

[data-jobvite-openings] .select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover {
    color: #1d2327;
}

[data-jobvite-openings] .select2-container--default .select2-selection--multiple .select2-selection__clear {
    position: absolute;
    top: 50%;
    right: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    margin: 0;
    padding: 0;
    transform: translateY(-50%);
    color: #646569;
    font-size: 16px;
    font-weight: 600;
    line-height: 16px;
}

[data-jobvite-openings] .select2-container--default .select2-selection--multiple .select2-search--inline {
    float: none;
    flex: 1 1 8px;
    margin: 0;
}

[data-jobvite-openings] .select2-container--default .select2-selection--multiple .select2-search--inline .select2-search__field {
    margin: 0;
    padding: 0;
    height: 24px;
    min-height: 24px;
    font-family: inherit;
    font-size: 16px;
    font-weight: 400;
    line-height: 24px;
}

[data-jobvite-openings] .select2-container--default .select2-selection--multiple .select2-search--inline .select2-search__field::placeholder {
    color: inherit;
    opacity: 1;
}

/* Hidden until the script seats the menu on the field, so it never flashes in the wrong place. */
body > .select2-container--open:not(.jv-dropdown-ready) {
    visibility: hidden;
}

/* Sit on the field's bottom border. Select2's own top offset overlaps the control. */
.select2-dropdown.jv-openings-dropdown {
    margin: 0;
    border: 1px solid #646569;
    border-top: 0;
    border-radius: 0;
}

.select2-dropdown.jv-openings-dropdown .select2-results__option {
    padding: 10px 12px;
    font-size: 16px;
    line-height: 24px;
}

[data-jobvite-openings] .job_cards {
    position: relative;
}

[data-jobvite-openings] .jv-loader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

[data-jobvite-openings] .jv-skeleton-bar {
    display: inline-block;
    vertical-align: middle;
    width: 68%;
    height: 14px;
    border-radius: 2px;
    background: linear-gradient(90deg, #E4F2F8 0%, #f7fbfc 50%, #E4F2F8 100%);
    background-size: 200% 100%;
    animation: jv-skeleton 1.2s ease-in-out infinite;
}

[data-jobvite-openings] .jv-skeleton-bar-title {
    width: 82%;
}

[data-jobvite-openings] .jv-skeleton-bar-short {
    width: 48%;
}

[data-jobvite-openings] .jv-skeleton:nth-child(2n) .jv-skeleton-bar-title {
    width: 64%;
}

[data-jobvite-openings] .jv-skeleton:nth-child(3n) .jv-skeleton-bar {
    width: 52%;
}

@keyframes jv-skeleton {
    0% { background-position: 100% 0; }
    100% { background-position: -100% 0; }
}

@media (prefers-reduced-motion: reduce) {
    [data-jobvite-openings] .jv-skeleton-bar {
        animation: none;
    }
}

@media screen and (max-width: 576px) {
    [data-jobvite-openings] .filters .select .select2-container {
        width: 100% !important;
        min-width: 0;
    }
}
