/**
 * Tacweb Live-Suche - Frontend
 *
 * Bewusst ohne Theme-Abhängigkeit: alle Farben laufen über Custom Properties,
 * die im Backend überschrieben werden können.
 */
:root {
    --tac-ls-accent: #0f766e;
}

.tac-ls-anchor {
    position: relative;
}

.tac-ls-panel {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1050;
    display: none;
    max-height: min(70vh, 32rem);
    overflow-y: auto;
    margin-top: .25rem;
    padding: .25rem 0;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, .12);
    border-radius: .5rem;
    box-shadow: 0 .5rem 1.5rem rgba(0, 0, 0, .14);
    text-align: left;
    overscroll-behavior: contain;
}

.tac-ls-panel.is-open {
    display: block;
}

.tac-ls-group + .tac-ls-group {
    border-top: 1px solid rgba(0, 0, 0, .07);
}

.tac-ls-group-title {
    padding: .5rem .875rem .25rem;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #6b7280;
}

.tac-ls-item {
    display: flex;
    align-items: center;
    gap: .625rem;
    padding: .4rem .875rem;
    color: inherit;
    text-decoration: none;
}

.tac-ls-item:hover,
.tac-ls-item:focus,
.tac-ls-item.is-active {
    background: rgba(0, 0, 0, .05);
    color: inherit;
    text-decoration: none;
}

.tac-ls-thumb {
    flex: 0 0 auto;
    width: 2.75rem;
    height: 2.75rem;
    object-fit: contain;
    background: #fff;
    border-radius: .25rem;
}

.tac-ls-body {
    flex: 1 1 auto;
    min-width: 0;
}

.tac-ls-title {
    display: block;
    font-size: .875rem;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.tac-ls-meta {
    display: block;
    margin-top: .1rem;
    font-size: .72rem;
    color: #6b7280;
}

.tac-ls-price {
    flex: 0 0 auto;
    padding-left: .5rem;
    font-size: .875rem;
    font-weight: 700;
    white-space: nowrap;
}

.tac-ls-hl {
    padding: 0;
    background: transparent;
    color: inherit;
    font-weight: 700;
}

.tac-ls-note,
.tac-ls-empty {
    padding: .625rem .875rem;
    font-size: .82rem;
    color: #6b7280;
}

.tac-ls-note {
    border-bottom: 1px solid rgba(0, 0, 0, .07);
}

.tac-ls-all {
    display: block;
    padding: .625rem .875rem;
    border-top: 1px solid rgba(0, 0, 0, .07);
    color: var(--tac-ls-accent);
    font-size: .82rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
}

.tac-ls-all:hover,
.tac-ls-all:focus,
.tac-ls-all.is-active {
    background: rgba(0, 0, 0, .05);
    color: var(--tac-ls-accent);
    text-decoration: none;
}

/* Mobile Dropdown des NOVA-Headers darf den Vorschlagskasten nicht abschneiden */
.search-wrapper-dropdown .dropdown-menu {
    overflow: visible;
}

@media (max-width: 575.98px) {
    .tac-ls-panel {
        max-height: 60vh;
    }

    .tac-ls-thumb {
        width: 2.25rem;
        height: 2.25rem;
    }
}
