/* ==========================================================================
   BORA — BUSCA DE RESTAURANTES
   Escopo: tudo abaixo só se aplica dentro de body.bo-search
   Tokens de cor/medida: bora-tokens.css (carregado antes deste arquivo)
   ========================================================================== */

body.bo-search .bo-wrap a {
    text-decoration: none;
}

body.bo-search .bo-wrap button {
    font-family: inherit;
}

.bo-wrap {
    padding-bottom: 56px;
}

.bo-shell-s {
    max-width: 1320px;
    margin-inline: auto;
    padding-inline: 16px;
}

/* ---------- Faixa de busca ---------------------------------------------- */

.bo-hero {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #1E293B 0%, #0F172A 100%);
    padding: 40px 0 34px;
    margin-bottom: 22px;
}

.bo-hero::before {
    content: "";
    position: absolute;
    width: 520px;
    height: 520px;
    top: -260px;
    right: -120px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(var(--bo-accent-rgb), .22) 0%, transparent 70%);
    pointer-events: none;
}

.bo-hero::after {
    content: "";
    position: absolute;
    width: 420px;
    height: 420px;
    bottom: -300px;
    left: -100px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(var(--bo-ai-rgb), .20) 0%, transparent 70%);
    pointer-events: none;
}

.bo-hero-inner {
    position: relative;
    z-index: 2;
    max-width: 760px;
}

.bo-hero h1 {
    font-size: 30px;
    font-weight: 800;
    letter-spacing: -.025em;
    color: #fff;
    margin: 0 0 6px;
}

@media (max-width: 767px) {
    .bo-hero {
        padding: 28px 0 26px;
    }

    .bo-hero h1 {
        font-size: 23px;
    }
}

.bo-hero p {
    font-size: 14px;
    color: rgba(255, 255, 255, .72);
    margin: 0 0 18px;
    line-height: 1.55;
}

/* Selo da busca com IA */
.bo-ai-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 28px;
    padding: 0 12px;
    margin-bottom: 12px;
    border-radius: var(--bo-r-full);
    background: rgba(var(--bo-ai-rgb), .18);
    border: 1px solid rgba(var(--bo-ai-rgb), .45);
    color: #DDD2FF;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: .03em;
    text-transform: uppercase;
}

.bo-ai-badge .bo-ai-spark {
    animation: bo-spark 2.4s ease-in-out infinite;
}

@keyframes bo-spark {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: .55;
        transform: scale(.82);
    }
}

/* Campo principal */
.bo-searchbar {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bo-surface);
    border-radius: var(--bo-r-full);
    padding: 7px 7px 7px 20px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, .28);
    border: 2px solid transparent;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.bo-searchbar:focus-within {
    border-color: rgba(var(--bo-ai-rgb), .75);
    box-shadow: 0 12px 40px rgba(0, 0, 0, .28), 0 0 0 5px rgba(var(--bo-ai-rgb), .18);
}

.bo-searchbar > svg {
    flex-shrink: 0;
    color: var(--bo-ai);
}

.bo-searchbar input {
    flex: 1;
    min-width: 0;
    height: 46px;
    border: 0;
    outline: none;
    background: transparent;
    font-size: 15px;
    color: var(--bo-ink);
}

.bo-searchbar input::placeholder {
    color: var(--bo-faint);
}

.bo-searchbar button[type="submit"] {
    flex-shrink: 0;
    height: 46px;
    padding: 0 26px;
    border: 0;
    border-radius: var(--bo-r-full);
    background: linear-gradient(135deg, var(--bo-accent) 0%, var(--bo-accent-2) 100%);
    color: #fff;
    font-size: 14.5px;
    font-weight: 700;
    cursor: pointer;
    transition: filter .18s ease, transform .18s ease;
}

.bo-searchbar button[type="submit"]:hover {
    filter: brightness(1.08);
}

.bo-searchbar button[type="submit"]:active {
    transform: translateY(1px);
}

@media (max-width: 575px) {
    .bo-searchbar {
        padding-left: 14px;
        gap: 6px;
    }

    .bo-searchbar button[type="submit"] {
        padding: 0 16px;
        font-size: 0;
        width: 46px;
    }

    .bo-searchbar button[type="submit"]::after {
        content: "\f002";
        font-family: "Font Awesome 6 Free";
        font-weight: 900;
        font-size: 15px;
    }
}

/* Exemplos de pergunta em linguagem natural */
.bo-ai-hint {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
    font-size: 12.5px;
    color: rgba(255, 255, 255, .6);
}

.bo-ai-example {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 13px;
    border-radius: var(--bo-r-full);
    background: rgba(255, 255, 255, .1);
    border: 1px solid rgba(255, 255, 255, .16);
    color: rgba(255, 255, 255, .9);
    font-size: 12.5px;
    cursor: pointer;
    transition: all .18s ease;
}

.bo-ai-example:hover {
    background: rgba(var(--bo-ai-rgb), .32);
    border-color: rgba(var(--bo-ai-rgb), .7);
    color: #fff;
}

/* Aviso de que o resultado veio da IA */
.bo-ai-note {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 16px;
    margin-bottom: 18px;
    border-radius: var(--bo-r);
    background: var(--bo-ai-soft);
    border: 1px solid rgba(var(--bo-ai-rgb), .28);
    font-size: 13px;
    color: #4C1D95;
    line-height: 1.5;
}

.bo-ai-note svg {
    flex-shrink: 0;
    margin-top: 1px;
    color: var(--bo-ai);
}

.bo-ai-note strong {
    font-weight: 700;
}

.bo-ai-note.is-off {
    background: var(--bo-line-2);
    border-color: var(--bo-line);
    color: var(--bo-ink-2);
}

.bo-ai-note.is-off svg {
    color: var(--bo-muted);
}

/* ---------- Culinárias visíveis ----------------------------------------- */

.bo-block {
    margin-bottom: 20px;
}

.bo-block-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.bo-block-head h2 {
    font-size: 14px;
    font-weight: 800;
    letter-spacing: -.01em;
    color: var(--bo-ink);
    margin: 0;
}

.bo-block-head button {
    border: 0;
    background: transparent;
    color: var(--bo-accent);
    font-size: 12.5px;
    font-weight: 700;
    cursor: pointer;
    padding: 0;
}

.bo-cuisines {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    max-height: 44px;
    overflow: hidden;
    transition: max-height .25s ease;
}

.bo-cuisines.is-expanded {
    max-height: 480px;
    overflow-y: auto;
}

.bo-cuisine {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 36px;
    padding: 0 15px;
    border-radius: var(--bo-r-full);
    background: var(--bo-surface);
    border: 1px solid var(--bo-line);
    color: var(--bo-ink-2);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    user-select: none;
    transition: all .18s ease;
    margin: 0;
}

.bo-cuisine:hover {
    border-color: #D7DEE6;
    color: var(--bo-ink);
}

.bo-cuisine input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.bo-cuisine.is-on {
    background: var(--bo-accent);
    border-color: var(--bo-accent);
    color: #fff;
    box-shadow: 0 6px 16px var(--bo-accent-ring);
}

.bo-cuisine.is-on::before {
    content: "\f00c";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 10px;
}

/* ---------- Filtros ------------------------------------------------------ */

.bo-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    padding: 14px;
    background: var(--bo-surface);
    border: 1px solid var(--bo-line);
    border-radius: var(--bo-r);
    margin-bottom: 20px;
}

.bo-seg {
    display: inline-flex;
    gap: 3px;
    padding: 3px;
    background: var(--bo-line-2);
    border-radius: var(--bo-r-full);
}

.bo-seg a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 34px;
    padding: 0 15px;
    border-radius: var(--bo-r-full);
    font-size: 13px;
    font-weight: 600;
    color: var(--bo-muted);
    white-space: nowrap;
    transition: all .18s ease;
}

.bo-seg a:hover {
    color: var(--bo-ink);
}

.bo-seg a.is-on {
    background: var(--bo-surface);
    color: var(--bo-ink);
    box-shadow: var(--bo-sh-1);
}

.bo-filter-field {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    height: 40px;
    padding: 0 15px;
    border: 1px solid var(--bo-line);
    border-radius: var(--bo-r-full);
    font-size: 13px;
    color: var(--bo-ink-2);
    min-width: 210px;
}

.bo-filter-field label {
    margin: 0;
    font-weight: 600;
    white-space: nowrap;
    color: var(--bo-muted);
}

.bo-filter-field input[type="range"] {
    flex: 1;
    min-width: 0;
    accent-color: var(--bo-accent);
    cursor: pointer;
}

.bo-filter-field output {
    font-weight: 700;
    color: var(--bo-ink);
    white-space: nowrap;
    min-width: 46px;
    text-align: right;
}

.bo-loc {
    position: relative;
    flex: 1;
    min-width: 200px;
}

.bo-loc > svg {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    opacity: .45;
    pointer-events: none;
}

.bo-loc input {
    width: 100%;
    height: 40px;
    padding: 0 40px 0 38px;
    border: 1px solid var(--bo-line);
    border-radius: var(--bo-r-full);
    font-size: 13px;
    color: var(--bo-ink);
    outline: none;
    transition: border-color .18s ease, box-shadow .18s ease;
}

.bo-loc input:focus {
    border-color: var(--bo-accent);
    box-shadow: 0 0 0 4px var(--bo-accent-ring);
}

.bo-loc button {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    border: 0;
    border-radius: 50%;
    background: var(--bo-line-2);
    color: var(--bo-ink-2);
    cursor: pointer;
    font-size: 12px;
}

.bo-loc button:hover {
    background: var(--bo-accent);
    color: #fff;
}

.bo-clear {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 40px;
    padding: 0 16px;
    border-radius: var(--bo-r-full);
    border: 1px solid var(--bo-line);
    background: var(--bo-surface);
    color: var(--bo-muted);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all .18s ease;
}

.bo-clear:hover {
    color: var(--bo-red);
    border-color: var(--bo-red);
}

/* ---------- Resultados --------------------------------------------------- */

.bo-results-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.bo-results-head h2 {
    font-size: 18px;
    font-weight: 800;
    letter-spacing: -.015em;
    color: var(--bo-ink);
    margin: 0;
}

.bo-results-head span {
    font-size: 13px;
    color: var(--bo-muted);
}

/* ---------- Rolagem infinita -------------------------------------------- */

.bo-more {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 28px 0 8px;
}

.bo-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    height: 46px;
    padding: 0 26px;
    border: 1px solid var(--bo-line);
    border-radius: var(--bo-r-full);
    background: var(--bo-surface);
    color: var(--bo-ink);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: var(--bo-sh-1);
    transition: all .18s ease;
}

.bo-more-btn:hover {
    color: #fff;
    background: var(--bo-accent);
    border-color: var(--bo-accent);
    box-shadow: 0 8px 20px var(--bo-accent-ring);
}

.bo-more.is-loading .bo-more-btn {
    pointer-events: none;
    opacity: .6;
}

.bo-more.is-loading .bo-more-spin {
    display: inline-block;
}

.bo-more-spin {
    display: none;
    width: 17px;
    height: 17px;
    border: 2px solid var(--bo-line);
    border-top-color: var(--bo-accent);
    border-radius: 50%;
    animation: bo-spin .7s linear infinite;
}

@keyframes bo-spin {
    to {
        transform: rotate(360deg);
    }
}

.bo-more-end {
    font-size: 12.5px;
    color: var(--bo-faint);
}

/* ---------- Vazio -------------------------------------------------------- */

.bo-empty-state {
    text-align: center;
    padding: 64px 20px;
    background: var(--bo-surface);
    border: 1px dashed var(--bo-line);
    border-radius: var(--bo-r-lg);
}

.bo-empty-state .bo-empty-icon {
    font-size: 38px;
    opacity: .3;
}

.bo-empty-state h3 {
    font-size: 17px;
    font-weight: 800;
    color: var(--bo-ink);
    margin: 14px 0 6px;
}

.bo-empty-state p {
    font-size: 13.5px;
    color: var(--bo-muted);
    margin: 0 auto 18px;
    max-width: 420px;
    line-height: 1.55;
}

/* ---------- Ajustes do template base ------------------------------------ */

body.bo-search .header.fixed {
    box-shadow: 0 1px 0 var(--bo-line);
}

/* O autocomplete do Google precisa ficar acima da faixa escura. */
body.bo-search .pac-container {
    z-index: 2000;
}
