/* Listen-spezifische Styles. Gemeinsame Detail/Top-Bar/KI-Badge-Regeln in karriere.css */

.search-section { background: white; padding: 1.25rem 1rem 1rem; border-bottom: 1px solid var(--border); position: relative; z-index: 60; }
.search-container { max-width: 1000px; margin: 0 auto; }
.search-bar { display: flex; align-items: center; background: white; border: 1.5px solid var(--border); border-radius: 50px; transition: var(--transition); position: relative; }
.search-bar:focus-within { border-color: var(--accent); box-shadow: var(--shadow-focus); }
.search-suggest { position: absolute; top: calc(100% + 8px); left: 0; right: 0; background: white; border: 1px solid var(--border); border-radius: 16px; box-shadow: 0 12px 28px rgba(0,0,0,0.10); z-index: 60; padding: 0.375rem 0; }
.search-suggest-label { font-size: 0.6875rem; font-weight: 600; color: var(--text-muted); padding: 0.5rem 1rem 0.375rem; text-transform: uppercase; letter-spacing: 0.5px; }
.search-suggest-list { list-style: none; padding: 0; margin: 0; }
.search-suggest-item { display: flex; align-items: center; gap: 0.75rem; padding: 0.625rem 1rem; cursor: pointer; font-size: 0.9375rem; color: var(--text); transition: var(--transition); }
.search-suggest-item:hover, .search-suggest-item.active { background: var(--accent-light); color: var(--accent); }
.search-suggest-item svg { width: 16px; height: 16px; color: var(--text-muted); flex-shrink: 0; }
.search-suggest-item:hover svg, .search-suggest-item.active svg { color: var(--accent); }
.search-suggest-item small { color: var(--text-muted); font-size: 0.7rem; margin-left: 0.5rem; font-weight: 400; }
.search-clear { display: none; background: none; border: none; cursor: pointer; padding: 0.25rem; border-radius: 50%; color: var(--text-muted); align-items: center; justify-content: center; transition: var(--transition); margin-right: 0.25rem; flex-shrink: 0; }
.search-clear.is-visible { display: flex; }
.search-clear:hover { background: var(--bg-page); color: var(--accent); }
.search-clear svg { width: 14px; height: 14px; }
.search-field { flex: 1; display: flex; align-items: center; gap: 0.5rem; padding: 0 1rem; min-width: 0; position: relative; }
.search-field svg { width: 18px; height: 18px; color: var(--text-muted); flex-shrink: 0; }
.search-field input { flex: 1; border: none; outline: none; font-size: 16px; padding: 0.75rem 0; background: transparent; min-width: 0; font-family: inherit; }
.search-divider { width: 1px; height: 24px; background: var(--border); flex-shrink: 0; }
.btn-search { display: inline-flex; align-items: center; gap: 0.375rem; padding: 0.625rem 1.25rem; margin: 4px; background: var(--accent); color: white; border: none; border-radius: 50px; font-weight: 600; font-size: 0.875rem; cursor: pointer; transition: var(--transition); font-family: inherit; }
.btn-search:hover { background: var(--accent-hover); }
.btn-search svg { width: 16px; height: 16px; }
@media (max-width: 768px) {
    .search-bar { flex-direction: column; background: transparent; border: none; border-radius: 0; overflow: visible; gap: 0.5rem; }
    .search-bar:focus-within { box-shadow: none; }
    .search-field { width: 100%; background: white; border: 1.5px solid var(--border); border-radius: 50px; transition: var(--transition); }
    .search-field:focus-within { border-color: var(--accent); box-shadow: var(--shadow-focus); }
    .search-divider { display: none; }
    .btn-search { width: 100%; margin: 0; justify-content: center; padding: 0.75rem 1rem; }
}

.container { max-width: 1400px; margin: 0 auto; padding: 0.875rem 1rem; display: flex; gap: 1rem; align-items: flex-start; }
.left-col { width: 420px; min-width: 360px; flex-shrink: 0; }
.right-col {
    flex: 1; min-width: 0; background: white;
    border: 1px solid var(--border); border-radius: var(--radius);
    position: sticky; top: 60px;
    max-height: calc(100vh - 72px);
    overflow-y: auto; padding: 1.5rem;
    align-self: flex-start;
    margin-top: 2.4rem;
}
/* Mobile-Sheet-Elemente standardmäßig versteckt */
.mobile-detail-header, .mobile-detail-backdrop, .mobile-detail-close { display: none; }
@media (max-width: 1024px) {
    .container { display: block; max-width: 1000px; }
    .left-col { width: auto; min-width: 0; }
    .right-col {
        display: block;
        position: fixed; left: 0; right: 0; top: 110px; z-index: 1000;
        margin: 0; padding: 0; border: none;
        border-radius: 20px 20px 0 0;
        box-shadow: 0 -6px 28px rgba(0,0,0,0.18);
        max-height: none; background: white;
        height: calc(100vh - 110px);
        height: calc(100dvh - 110px);
        bottom: auto;
        overflow-y: scroll;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
        touch-action: pan-y;
        transform: translateY(100%);
        transition: transform 0.25s ease-out;
        pointer-events: none;
    }
    body.mobile-detail-open .right-col { transform: translateY(0); pointer-events: auto; }
    body.mobile-detail-open { overflow: hidden; }
    .mobile-detail-backdrop {
        display: block; position: fixed; inset: 0;
        background: rgba(0,0,0,0); z-index: 999;
        pointer-events: none;
        transition: background 0.22s ease-out;
    }
    body.mobile-detail-open .mobile-detail-backdrop { background: rgba(0,0,0,0.45); pointer-events: auto; cursor: pointer; }
    .right-col > .job-detail { padding: 50px 1.25rem 4rem; }
    .mobile-detail-header {
        display: block; position: sticky; top: 0; z-index: 5;
        padding: 0.625rem 1rem 0.5rem;
        background: white;
        border-radius: 20px 20px 0 0;
    }
    .mobile-detail-handle { width: 40px; height: 4px; border-radius: 2px; background: var(--border); margin: 0 auto; }
    .mobile-detail-close {
        display: flex;
        position: fixed;
        top: 122px; right: 14px;
        z-index: 1002;
        width: 36px; height: 36px;
        border-radius: 50%;
        background: white; border: 1px solid var(--border);
        align-items: center; justify-content: center;
        cursor: pointer; color: var(--text-secondary);
        font-family: inherit;
        padding: 0;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.12s ease-out, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
    }
    body.mobile-detail-open .mobile-detail-close {
        opacity: 1;
        pointer-events: auto;
        transition: opacity 0.18s ease-out 0.12s, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
    }
    .mobile-detail-close:hover { background: var(--accent-light); color: var(--accent); border-color: var(--accent); }
    .mobile-detail-close svg { width: 16px; height: 16px; }
}

.standort-heading { font-size: 1.375rem; font-weight: 700; line-height: 1.3; margin-bottom: 0.875rem; }
.standort-heading strong { color: var(--accent); font-weight: 700; }
.standort-back { display: inline-flex; align-items: center; gap: 0.25rem; font-size: 0.8125rem; color: var(--text-muted); text-decoration: none; margin-bottom: 0.5rem; transition: var(--transition); }
.standort-back:hover { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.job-card.active { border-color: white; background: var(--success-light); }

.results-info { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.875rem; padding: 0 0.125rem; }
.results-count-wrap { font-size: 0.875rem; color: var(--text-secondary); }
.results-count { font-weight: 700; color: var(--text); }
.results-actions { display: flex; gap: 0.875rem; align-items: center; }
.saved-toggle { display: inline-flex; align-items: center; gap: 0.375rem; font-size: 0.8125rem; color: var(--text-secondary); cursor: pointer; transition: var(--transition); }
.saved-toggle[hidden] { display: none; }
.saved-toggle:hover { color: var(--accent); }
.saved-toggle.active { color: var(--accent); font-weight: 600; }
.saved-toggle svg { width: 14px; height: 14px; }
.saved-count { background: var(--accent); color: white; padding: 0 0.375rem; border-radius: 10px; font-size: 0.6875rem; min-width: 16px; text-align: center; }
.reset-link { font-size: 0.8125rem; color: var(--accent); cursor: pointer; }
.reset-link[hidden] { display: none; }
.reset-link:hover { text-decoration: underline; }

.job-list { display: flex; flex-direction: column; gap: 0.5rem; scroll-margin-top: 60px; }
#first-job-card { scroll-margin-top: 60px; }
.job-card {
    display: block;
    padding: 0.875rem 1rem;
    background: white;
    border: 1.5px solid transparent;
    border-radius: var(--radius-sm);
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
    cursor: pointer;
}
.job-card:hover { border-color: var(--success); box-shadow: 0 4px 12px rgba(0,0,0,0.05); }
.job-card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 0.75rem; }
.job-card-info { flex: 1; min-width: 0; }
.job-title { font-size: 0.9375rem; font-weight: 600; margin-bottom: 0.25rem; line-height: 1.35; }
.job-company { font-size: 0.8125rem; color: var(--text-secondary); margin-bottom: 0.25rem; }
.job-location { display: inline-flex; align-items: center; gap: 0.25rem; font-size: 0.75rem; color: var(--text-muted); flex-wrap: wrap; }
.job-location svg { width: 12px; height: 12px; }
.job-distance { color: var(--accent); font-weight: 500; }
.btn-save { background: none; border: none; cursor: pointer; padding: 0.25rem; border-radius: 6px; transition: var(--transition); flex-shrink: 0; }
.btn-save:hover { background: var(--accent-light); }
.btn-save svg { width: 18px; height: 18px; color: var(--text-muted); transition: var(--transition); }
.btn-save:hover svg { color: var(--accent); }
.btn-save.saved svg { fill: var(--accent); color: var(--accent); }
.job-badges { display: flex; flex-wrap: wrap; gap: 0.25rem; margin-top: 0.5rem; }
.job-badge { display: inline-block; padding: 0.125rem 0.5rem; border-radius: 4px; background: var(--accent-light); color: var(--accent); font-size: 0.6875rem; font-weight: 500; }
.job-card-top-badges { display: flex; flex-wrap: wrap; gap: 0.375rem; margin-bottom: 0.625rem; }
.badge-quickapply { display: inline-block; padding: 0.25rem 0.625rem; border-radius: 4px; background: var(--success); color: #1f2937; font-size: 0.6875rem; font-weight: 600; letter-spacing: 0.2px; }
.badge-urgent { display: inline-block; padding: 0.25rem 0.625rem; border-radius: 4px; background: var(--accent); color: white; font-size: 0.6875rem; font-weight: 600; letter-spacing: 0.2px; }
.job-card.job-card-urgent { border-left: 3px solid var(--accent); }
.job-badge-salary { background: #f3f4f6; color: #6b7280; font-weight: 500; }
.job-badge-shift { background: #fef3c7; color: #92400e; font-weight: 600; }
.meta-salary { display: inline-flex; align-items: center; padding: 0.125rem 0.625rem; border-radius: 999px; background: #f3f4f6; color: #6b7280; font-weight: 500; font-size: 0.8125rem; }
.meta-shift { display: inline-flex; align-items: center; padding: 0.125rem 0.625rem; border-radius: 999px; background: #fef3c7; color: #92400e; font-weight: 600; font-size: 0.8125rem; }

.empty-state { text-align: center; padding: 3rem 1rem; color: var(--text-muted); }
.empty-state svg { width: 48px; height: 48px; opacity: 0.3; margin-bottom: 0.75rem; }

.loading { text-align: center; padding: 2rem 0; }
.spinner { width: 28px; height: 28px; border: 3px solid var(--border); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.7s linear infinite; margin: 0 auto 0.75rem; }
@keyframes spin { to { transform: rotate(360deg); } }

.load-more-container { text-align: center; padding: 0.75rem 0; }
.load-more-container[hidden] { display: none; }
.btn-load-more { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.5rem 1.25rem; background: white; color: var(--accent); border: 1.5px solid var(--accent); border-radius: 50px; font-weight: 600; font-size: 0.8125rem; cursor: pointer; transition: var(--transition); font-family: inherit; }
.btn-load-more:hover { background: var(--accent); color: white; }
.btn-load-more:disabled { opacity: 0.5; cursor: not-allowed; }

.pagination { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 0.125rem; padding: 0.75rem 0.5rem 0.25rem; opacity: 0.7; }
.pagination:hover { opacity: 1; }
.pg { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; padding: 0 0.375rem; border-radius: 4px; font-size: 0.6875rem; font-weight: 500; text-decoration: none; color: var(--text-muted); background: transparent; transition: var(--transition); }
.pg:hover { color: var(--accent); background: var(--accent-light); }
.pg-current { color: var(--accent); font-weight: 700; cursor: default; }
.pg-info { width: 100%; text-align: center; font-size: 0.6875rem; color: var(--text-muted); margin-top: 0.125rem; }
