/* OMS Jobs — styles for the markup this plugin generates.
   Card and detail layout come from the theme; only the plugin's own
   elements are styled here. */

.job-search-filter {
    display: none;
    gap: 1rem;
    flex-wrap: wrap;
}

#job-listing.loading {
    opacity: 0.5;
    pointer-events: none;
    transition: opacity 0.15s ease-in-out;
}

.oms-jobs-empty,
.oms-jobs-error {
    margin: 2rem 0;
    text-align: center;
}

/* Tags rendered by [oms-tags] */
.oms-job-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin: 0.5rem 0 0;
    padding: 0;
    list-style: none;
}

.oms-job-tags .oms-job-tag {
    display: inline-block;
    margin: 0;
    padding: 0.15em 0.7em;
    border: 1px solid currentColor;
    border-radius: 999px;
    font-size: 0.8em;
    line-height: 1.6;
    opacity: 0.75;
    white-space: nowrap;
}

/* Recruitee rich text arrives as its own block markup, so the wrapper must
   not add paragraph spacing of its own. */
.tm-job-text > :first-child { margin-top: 0; }
.tm-job-text > :last-child  { margin-bottom: 0; }

/* ---------------------------------------------- PLZ / Ort autocomplete ---
   Visual language borrowed from oms-standorte's location search: white
   rounded panel, charcoal hairline border, brand accent on the active row.
   Theme variables with fallbacks, so it degrades if the theme changes. */

.job-search-input-wrapper {
    position: relative;
    flex: 1 1 auto;
    min-width: 0;
}

.job-search-input-wrapper input {
    width: 100%;
    box-sizing: border-box;
}

.job-search-suggestions {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    z-index: 120;
    margin: 0;
    padding: 0.4em;
    list-style: none;
    max-height: 20rem;
    overflow-y: auto;
    background-color: var(--color-white, #fff);
    border: 1px solid var(--color-charcoal-200, #e2e2e2);
    border-radius: 20px;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.08);
}

.job-search-suggestion {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1em;
    margin: 0;
    padding: 0.55em 1em;
    border-radius: 999px;
    cursor: pointer;
    line-height: 1.4;
}

.job-search-suggestion:hover,
.job-search-suggestion.is-active {
    background-color: var(--color-charcoal-100, #f2f2f2);
}

.job-search-suggestion-label {
    font-weight: 600;
}

.job-search-suggestion-count {
    flex: 0 0 auto;
    font-size: 0.85em;
    opacity: 0.6;
    white-space: nowrap;
}

.job-search-suggestion-branch {
    display: block;
    font-weight: 400;
    font-size: 0.82em;
    opacity: 0.6;
}

.job-search-suggestion-branch::before {
    content: "→ ";
}
