/* ===================== BUSCA DO SITE (Teófilo Decor) =====================
   Arquivo único, carregado em todas as páginas (home, blog e páginas de
   cidade), por isso as cores estão fixas em hexadecimal (cada layout usa
   nomes de variáveis CSS diferentes internamente). */

.tf-search-btn {
 display: inline-flex;
 align-items: center;
 justify-content: center;
 width: 38px;
 height: 38px;
 border-radius: 50%;
 border: 1px solid rgba(15, 59, 46, 0.18);
 background: transparent;
 color: #0F3B2E;
 cursor: pointer;
 transition: all 0.25s ease;
 flex-shrink: 0;
}
.tf-search-btn:hover,
.tf-search-btn:focus-visible {
 background: #0F3B2E;
 border-color: #0F3B2E;
 color: #fff;
 outline: none;
}
.tf-search-btn svg,
.tf-search-btn i {
 width: 18px;
 height: 18px;
 pointer-events: none;
}
/* Nas páginas com header fixo/transparente sobre a foto do hero (home e
   blog), o ícone começa branco e só fica verde quando o header "ganha"
   fundo sólido (classe .scrolled) — mesmo padrão já usado no botão do
   menu mobile (.menu-toggle) dessas páginas. */
#main-header .tf-search-btn {
 color: #FFFFFF;
 border-color: rgba(255, 255, 255, 0.45);
}
#main-header .tf-search-btn:hover,
#main-header .tf-search-btn:focus-visible {
 background: #FFFFFF;
 color: #0F3B2E;
 border-color: #FFFFFF;
}
#main-header.scrolled .tf-search-btn {
 color: #0F3B2E;
 border-color: rgba(15, 59, 46, 0.18);
}
#main-header.scrolled .tf-search-btn:hover,
#main-header.scrolled .tf-search-btn:focus-visible {
 background: #0F3B2E;
 color: #fff;
 border-color: #0F3B2E;
}

.tf-search-overlay {
 position: fixed;
 inset: 0;
 z-index: 3000;
 background: rgba(15, 26, 22, 0.55);
 backdrop-filter: blur(3px);
 display: flex;
 align-items: flex-start;
 justify-content: center;
 padding: 8vh 20px 20px;
 opacity: 0;
 pointer-events: none;
 transition: opacity 0.25s ease;
}
.tf-search-overlay.active {
 opacity: 1;
 pointer-events: auto;
}

.tf-search-modal {
 width: 100%;
 max-width: 620px;
 background: #F9F7F2;
 border-radius: 14px;
 box-shadow: 0 30px 70px rgba(0, 0, 0, 0.35);
 overflow: hidden;
 transform: translateY(-16px);
 transition: transform 0.25s ease;
 max-height: 78vh;
 display: flex;
 flex-direction: column;
}
.tf-search-overlay.active .tf-search-modal {
 transform: translateY(0);
}

.tf-search-field {
 display: flex;
 align-items: center;
 gap: 12px;
 padding: 18px 20px;
 border-bottom: 1px solid #E7E1D5;
 flex-shrink: 0;
}
.tf-search-field svg,
.tf-search-field i {
 width: 20px;
 height: 20px;
 color: #C6A155;
 flex-shrink: 0;
}
.tf-search-field input {
 flex: 1;
 border: none;
 background: transparent;
 outline: none;
 font-family: 'Plus Jakarta Sans', sans-serif;
 font-size: 1rem;
 color: #1F2A24;
}
.tf-search-field input::placeholder {
 color: #8A968F;
}
.tf-search-close {
 border: none;
 background: transparent;
 cursor: pointer;
 color: #5B6B63;
 width: 30px;
 height: 30px;
 display: flex;
 align-items: center;
 justify-content: center;
 border-radius: 50%;
 flex-shrink: 0;
 transition: background 0.2s ease;
}
.tf-search-close:hover { background: #E7E1D5; }
.tf-search-close svg,
.tf-search-close i { width: 18px; height: 18px; }

.tf-search-results {
 overflow-y: auto;
 padding: 8px;
}
.tf-search-hint,
.tf-search-empty {
 padding: 28px 20px;
 text-align: center;
 color: #5B6B63;
 font-size: 0.92rem;
}
.tf-search-result {
 display: flex;
 gap: 14px;
 align-items: flex-start;
 padding: 14px 12px;
 border-radius: 10px;
 text-decoration: none;
 color: inherit;
 transition: background 0.15s ease;
}
.tf-search-result:hover,
.tf-search-result.is-active {
 background: #F1EDE4;
}
.tf-search-result-icon {
 width: 36px;
 height: 36px;
 border-radius: 8px;
 background: #0F3B2E;
 color: #fff;
 display: flex;
 align-items: center;
 justify-content: center;
 flex-shrink: 0;
}
.tf-search-result-icon svg,
.tf-search-result-icon i { width: 16px; height: 16px; }
.tf-search-result-body { min-width: 0; }
.tf-search-result-title {
 font-family: 'Cormorant Garamond', serif;
 font-size: 1.15rem;
 font-weight: 600;
 color: #1F2A24;
 margin: 0 0 3px;
 line-height: 1.25;
}
.tf-search-result-title mark,
.tf-search-result-excerpt mark {
 background: rgba(198, 161, 85, 0.35);
 color: inherit;
 border-radius: 2px;
 padding: 0 1px;
}
.tf-search-result-excerpt {
 font-size: 0.85rem;
 color: #5B6B63;
 margin: 0 0 6px;
 overflow: hidden;
 display: -webkit-box;
 -webkit-line-clamp: 2;
 -webkit-box-orient: vertical;
}
.tf-search-result-badge {
 display: inline-block;
 font-size: 0.65rem;
 letter-spacing: 1px;
 text-transform: uppercase;
 font-weight: 700;
 color: #A8833E;
}

@media (max-width: 640px) {
 .tf-search-overlay { padding: 0; align-items: stretch; }
 .tf-search-modal { max-width: none; height: 100%; max-height: none; border-radius: 0; }
}
