/* ==========================================================================
   LIVE SEARCH – wyniki + warianty wyświetlania
   Warianty: nakładka (overlay), pasek inline, rozwijany pasek (dropdown).
   Uwaga: nakładka ma jasne tło, więc wszystkie warianty = jasny motyw wyników.
   Plik: assets/css/components/live-search.css
   ========================================================================== */

/* --- Wspólne: wyniki (jasna karta) --- */
.aurora-ls-results {
    display: none;
    background: #fff;
    border: 1px solid var(--aurora-border, #e2e8f0);
    border-radius: 14px;
    box-shadow: 0 20px 45px rgba(15, 23, 42, .14);
    overflow: hidden;
}
.aurora-ls-results.is-open { display: block; }
.aurora-ls-results.is-loading { opacity: .55; }

.aurora-ls-list { list-style: none; margin: 0; padding: 6px; max-height: 56vh; overflow-y: auto; }
.aurora-ls-item a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 10px;
    border-radius: 10px;
    text-decoration: none;
    transition: background .15s ease;
}
.aurora-ls-item a:hover { background: #fff8ec; }
.aurora-ls-thumb { width: 46px; height: 46px; border-radius: 8px; overflow: hidden; flex-shrink: 0; background: #f8fafc; }
.aurora-ls-thumb img { width: 100%; height: 100%; object-fit: cover; }
.aurora-ls-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; text-align: left; }
.aurora-ls-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--aurora-navy, #1e293b);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.aurora-ls-price { font-size: 13px; color: var(--aurora-slate, #64748b); }
.aurora-ls-price del { opacity: .6; margin-right: 5px; }
.aurora-ls-price ins { text-decoration: none; color: var(--aurora-navy, #1e293b); }
.aurora-ls-all {
    display: block;
    text-align: center;
    padding: 12px;
    margin: 6px;
    border-radius: 10px;
    background: var(--aurora-gradient, linear-gradient(135deg, #f59e0b, #6366f1));
    color: #fff;
    font-weight: 600;
    font-size: 13.5px;
    text-decoration: none;
}
.aurora-ls-all:hover { filter: brightness(1.05); }
.aurora-ls-empty { text-align: center; padding: 24px; color: var(--aurora-slate, #64748b); font-size: 14px; }

/* --- Wariant: NAKŁADKA (wyniki pod dużym polem) --- */
.search-bar-overlay .aurora-ls-results {
    max-width: 640px;
    margin: 18px auto 0;
    text-align: left;
}

/* --- Wariant: PASEK INLINE w nagłówku --- */
.aurora-inline-search {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    width: clamp(180px, 24vw, 320px);
    padding: 0 14px;
    height: 44px;
    background: var(--aurora-bg-light, #f8fafc);
    border: 1px solid var(--aurora-border, #e2e8f0);
    border-radius: 50px;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}
.aurora-inline-search:focus-within {
    border-color: var(--aurora-accent, #f59e0b);
    box-shadow: 0 0 0 3px rgba(245, 158, 11, .12);
    background: #fff;
}
.aurora-inline-search-icon { color: var(--aurora-slate, #64748b); font-size: 18px; flex-shrink: 0; }
.aurora-inline-search .aurora-ls-input {
    flex: 1;
    min-width: 0;
    border: none;
    background: transparent;
    outline: none;
    font-size: 14px;
    color: var(--aurora-navy, #1e293b);
}
.aurora-inline-search .aurora-ls-results {
    position: absolute;
    top: calc(100% + 12px);
    left: 0;
    width: 380px;
    max-width: min(380px, 92vw);
    z-index: 1002;
}

/* Ikona-fallback (mobile) dla wariantu inline */
.aurora-search-mobile-only { display: none; }

/* --- Wariant: ROZWIJANY pasek pod nagłówkiem --- */
.aurora-search-dd {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1500;
    background: #fff;
    box-shadow: 0 20px 45px rgba(15, 23, 42, .12);
    border-top: 1px solid var(--aurora-border, #e2e8f0);
    padding: 18px 0;
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    transition: opacity .25s ease, transform .25s ease, visibility .25s ease;
}
.aurora-search-dd.is-open { opacity: 1; visibility: visible; transform: translateY(0); }
.aurora-search-dd .aurora-ls-wrap { position: relative; max-width: 720px; margin: 0 auto; padding: 0 20px; }
.aurora-search-inputrow {
    display: flex;
    align-items: center;
    gap: 12px;
    height: 56px;
    padding: 0 20px;
    border: 2px solid var(--aurora-border, #e2e8f0);
    border-radius: 50px;
    transition: border-color .2s ease;
}
.aurora-search-inputrow:focus-within { border-color: var(--aurora-indigo, #6366f1); }
.aurora-search-inputrow i { color: var(--aurora-slate, #64748b); font-size: 20px; }
.aurora-search-dd .aurora-ls-input {
    flex: 1;
    min-width: 0;
    border: none;
    background: transparent;
    outline: none;
    font-size: 1.1rem;
    color: var(--aurora-navy, #1e293b);
}
.aurora-search-dd-close {
    border: none;
    background: transparent;
    color: var(--aurora-slate, #64748b);
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}
.aurora-search-dd-close:hover { color: var(--aurora-navy, #1e293b); }
.aurora-search-dd .aurora-ls-results {
    position: absolute;
    top: calc(100% + 10px);
    left: 20px;
    right: 20px;
}

/* --- Mobile: pasek inline ustępuje miejsca ikonie (nakładka) --- */
@media (max-width: 1024px) {
    .aurora-inline-search { display: none; }
    .aurora-search-mobile-only { display: flex; }
}
