import{r as e,j as s,L as a,c as t}from"./vendor-uppOmrO1-1770496120205.js";import{u as r,N as d,B as l,F as o}from"./index-DB8ah19g-1770496120205.js";import{F as i,n,B as m,U as c,a0 as x,v as p,a1 as u,z as b,T as h,t as g}from"./icons-Dn7aDdFT-1770496120205.js";const j=t("https://enkijdqewoikjczpfgch.supabase.co","eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6ImVua2lqZHFld29pa2pjenBmZ2NoIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NTYxMjY1NDgsImV4cCI6MjA3MTcwMjU0OH0.jti_3Veh6rH12-_WcVKgnbFvpsPVu_CLjY5GLvVpBBk"),f=[{id:"empresarial",nome:"Empresarial",descricao:"Para empresas",icon:n,cor:"yellow"},{id:"mei",nome:"MEI",descricao:"Microempreendedor Individual",icon:m,cor:"orange"},{id:"adesao",nome:"Por Adesão",descricao:"Sindicatos e associações",icon:c,cor:"cyan"},{id:"pessoa-fisica",nome:"Pessoa Física",descricao:"Planos individuais",icon:x,cor:"purple"}],v=()=>{var t;const[n,m]=e.useState(""),[c,x]=e.useState(null),[v,N]=e.useState("todas"),[w,y]=e.useState("todas"),[C,k]=e.useState([]),[I,L]=e.useState(!0),[S,P]=e.useState(!0);r({title:"Tabelas de Preços de Planos de Saúde 2025 | WebPlan",description:"Compare tabelas de preços de planos de saúde empresariais, por adesão e pessoa física. Encontre o melhor plano para você com valores atualizados.",keywords:"tabelas de preços planos de saúde, valores planos de saúde, cotação plano de saúde, preços atualizados, plano empresarial",canonical:"https://webplansaude.com/tabelas"}),e.useEffect(()=>{!function(){return e=this,s=null,a=function*(){try{const{data:e,error:s}=yield j.from("landing_pages").select("id, slug, title, meta_description, operadora, localidade, tipo_empresa, h1").eq("status","published").order("title",{ascending:!0});if(s)return;k(e||[])}catch(e){}finally{L(!1)}},new Promise((t,r)=>{var d=e=>{try{o(a.next(e))}catch(s){r(s)}},l=e=>{try{o(a.throw(e))}catch(s){r(s)}},o=e=>e.done?t(e.value):Promise.resolve(e.value).then(d,l);o((a=a.apply(e,s)).next())});var e,s,a}()},[]);const E=e.useMemo(()=>{const e=new Set;return C.forEach(s=>{s.operadora&&e.add(s.operadora)}),Array.from(e).sort()},[C]),F=e.useMemo(()=>{const e=new Set;return C.forEach(s=>{s.localidade&&e.add(s.localidade)}),Array.from(e).sort()},[C]),M=e.useMemo(()=>{let e=C;if(c&&(e=e.filter(e=>(e=>{if(e.tipo_empresa){const s=e.tipo_empresa.toLowerCase().trim();if("adesão"===s||"adesao"===s)return"adesao";if("empresarial"===s)return"empresarial";if("mei"===s)return"mei";if("pessoa fisica"===s||"pessoa física"===s||"pessoa-fisica"===s)return"pessoa-fisica"}const s=e.slug.toLowerCase();return s.includes("oab")||s.includes("crea")||s.includes("enfermeiros")||s.includes("medicos")||s.includes("advogados")||s.includes("engenheiros")?"adesao":s.includes("mei")?"mei":s.includes("empresarial")||s.includes("empresas")||s.includes("pme")?"empresarial":s.includes("senior")||s.includes("individual")||s.includes("familiar")||s.includes("pf")?"pessoa-fisica":"empresarial"})(e)===c)),"todas"!==v&&(e=e.filter(e=>e.operadora===v)),"todas"!==w&&(e=e.filter(e=>e.localidade===w)),n){const s=n.toLowerCase();e=e.filter(e=>{var a,t;return e.title.toLowerCase().includes(s)||e.meta_description.toLowerCase().includes(s)||(null==(a=e.operadora)?void 0:a.toLowerCase().includes(s))||(null==(t=e.localidade)?void 0:t.toLowerCase().includes(s))||e.h1.toLowerCase().includes(s)})}return e},[C,c,v,w,n]),_=e.useMemo(()=>{const e={};return M.forEach(s=>{const a=s.operadora||"Outras";e[a]||(e[a]=[]),e[a].push(s)}),e},[M]),z=()=>{x(null),N("todas"),y("todas"),m(""),P(!0)};return s.jsxs(s.Fragment,{children:[s.jsx(d,{}),s.jsx("div",{className:"pt-32 pb-6 bg-white border-b border-gray-200 relative z-10",children:s.jsx("div",{className:"container mx-auto px-4",children:s.jsx(l,{items:[{label:"Tabelas de Preços",href:"/tabelas"}]})})}),s.jsx("div",{className:"min-h-screen bg-gradient-to-br from-slate-50 via-blue-50 to-slate-100",children:s.jsx("div",{className:"container mx-auto px-4 py-8",children:s.jsxs("main",{className:"max-w-7xl mx-auto",children:[s.jsxs("div",{className:"text-center mb-8 md:mb-12",children:[s.jsxs("div",{className:"flex items-center justify-center gap-2 md:gap-3 mb-3 md:mb-4",children:[s.jsx(i,{className:"w-8 md:w-12 h-8 md:h-12 text-blue-600"}),s.jsx("h1",{className:"text-2xl md:text-4xl lg:text-5xl font-bold text-gray-900",children:"Tabelas de Preços"})]}),s.jsx("p",{className:"text-base md:text-xl text-gray-600 max-w-3xl mx-auto px-4",children:"Encontre as melhores tabelas de preços de planos de saúde atualizadas. Compare valores e escolha o plano ideal para você ou sua empresa."}),s.jsxs("div",{className:"flex flex-wrap justify-center gap-3 md:gap-6 mt-6 md:mt-8",children:[s.jsxs("div",{className:"bg-white rounded-lg md:rounded-xl p-3 md:p-4 shadow-md border border-blue-100 min-w-[100px] md:min-w-[140px]",children:[s.jsx("div",{className:"text-2xl md:text-3xl font-bold text-blue-600",children:C.length}),s.jsx("div",{className:"text-xs md:text-sm text-gray-600",children:"Tabelas Disponíveis"})]}),s.jsxs("div",{className:"hidden md:block bg-white rounded-lg md:rounded-xl p-3 md:p-4 shadow-md border border-green-100 min-w-[100px] md:min-w-[140px]",children:[s.jsx("div",{className:"text-2xl md:text-3xl font-bold text-green-600",children:E.length}),s.jsx("div",{className:"text-xs md:text-sm text-gray-600",children:"Operadoras"})]}),s.jsxs("div",{className:"hidden md:block bg-white rounded-lg md:rounded-xl p-3 md:p-4 shadow-md border border-purple-100 min-w-[100px] md:min-w-[140px]",children:[s.jsx("div",{className:"text-2xl md:text-3xl font-bold text-purple-600",children:F.length}),s.jsx("div",{className:"text-xs md:text-sm text-gray-600",children:"Estados"})]})]})]}),S&&s.jsxs("div",{className:"bg-gradient-to-br from-blue-600 to-blue-700 rounded-xl md:rounded-2xl shadow-2xl p-5 md:p-8 mb-6 md:mb-8 text-white",children:[s.jsx("h2",{className:"text-xl md:text-2xl lg:text-3xl font-bold text-center mb-2 md:mb-3",children:"Que tipo de plano você procura?"}),s.jsx("p",{className:"text-sm md:text-base text-center text-blue-100 mb-6 md:mb-8",children:"Selecione a categoria para ver as tabelas mais relevantes"}),s.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-3 md:gap-4",children:f.map(e=>{const a=e.icon;return s.jsxs("button",{onClick:()=>(e=>{x(e),P(!1)})(e.id),className:"bg-white text-gray-900 rounded-lg md:rounded-xl p-4 md:p-6 hover:shadow-2xl transition-all duration-300 transform hover:scale-105 group",children:[s.jsx("div",{className:"w-12 md:w-16 h-12 md:h-16 mx-auto mb-3 md:mb-4 rounded-full bg-".concat(e.cor,"-100 flex items-center justify-center group-hover:bg-").concat(e.cor,"-200 transition-colors"),children:s.jsx(a,{className:"w-6 md:w-8 h-6 md:h-8 text-".concat(e.cor,"-600")})}),s.jsx("h3",{className:"text-lg md:text-xl font-bold mb-1 md:mb-2",children:e.nome}),s.jsx("p",{className:"text-xs md:text-sm text-gray-600",children:e.descricao}),s.jsxs("div",{className:"mt-3 md:mt-4 flex items-center justify-center gap-2 text-blue-600 font-semibold text-sm md:text-base",children:["Ver tabelas ",s.jsx(p,{className:"w-3 md:w-4 h-3 md:h-4"})]})]},e.id)})}),s.jsx("div",{className:"text-center mt-6",children:s.jsx("button",{onClick:()=>P(!1),className:"text-blue-100 hover:text-white underline text-sm",children:"Pular e ver todas as tabelas"})})]}),!S&&s.jsxs(s.Fragment,{children:[c&&s.jsx("div",{className:"bg-blue-50 border border-blue-200 rounded-lg p-4 mb-6",children:s.jsxs("div",{className:"flex items-center justify-between flex-wrap gap-3",children:[s.jsxs("div",{className:"flex items-center gap-2 text-sm",children:[s.jsx(u,{className:"w-4 h-4 text-blue-600"}),s.jsx("span",{className:"text-gray-600",children:"Filtrando por:"}),s.jsx("span",{className:"bg-blue-600 text-white px-3 py-1 rounded-full text-xs font-semibold",children:null==(t=f.find(e=>e.id===c))?void 0:t.nome})]}),s.jsx("button",{onClick:z,className:"text-blue-600 hover:text-blue-700 text-sm font-medium underline",children:"Limpar filtros"})]})}),s.jsxs("div",{className:"bg-white rounded-lg md:rounded-xl shadow-lg p-4 md:p-6 mb-6 md:mb-8 border border-gray-200",children:[s.jsx("div",{className:"mb-4 md:mb-6",children:s.jsxs("div",{className:"relative",children:[s.jsx(b,{className:"absolute left-3 md:left-4 top-1/2 transform -translate-y-1/2 text-gray-400 w-4 md:w-5 h-4 md:h-5"}),s.jsx("input",{type:"text",placeholder:"Buscar por operadora, localidade...",value:n,onChange:e=>m(e.target.value),className:"w-full pl-10 md:pl-12 pr-3 md:pr-4 py-2 md:py-3 border border-gray-300 rounded-lg focus:ring-2 focus:ring-blue-500 focus:border-transparent text-sm md:text-base text-gray-900 placeholder-gray-400"})]})}),s.jsxs("div",{className:"space-y-4 md:space-y-6",children:[s.jsxs("div",{children:[s.jsx("label",{className:"block text-xs md:text-sm font-semibold text-gray-700 mb-2",children:"Operadora"}),s.jsxs("select",{value:v,onChange:e=>N(e.target.value),className:"w-full px-3 md:px-4 py-2 border border-gray-300 rounded-lg focus:ring-2 focus:ring-blue-500 focus:border-transparent text-sm md:text-base text-gray-900",children:[s.jsx("option",{value:"todas",children:"Todas as operadoras"}),E.map(e=>s.jsx("option",{value:e,children:e},e))]})]}),s.jsxs("div",{children:[s.jsx("label",{className:"block text-xs md:text-sm font-semibold text-gray-700 mb-2 md:mb-3",children:"Localidade"}),s.jsxs("div",{className:"flex flex-wrap gap-1.5 md:gap-2",children:[s.jsx("button",{onClick:()=>y("todas"),className:"px-3 md:px-4 py-1.5 md:py-2 rounded-md md:rounded-lg font-medium text-xs md:text-sm transition-all ".concat("todas"===w?"bg-purple-600 text-white shadow-md":"bg-gray-100 text-gray-700 hover:bg-gray-200"),children:"Todas"}),F.map(e=>s.jsx("button",{onClick:()=>y(e),className:"px-3 md:px-4 py-1.5 md:py-2 rounded-md md:rounded-lg font-medium text-xs md:text-sm transition-all ".concat(w===e?"bg-purple-600 text-white shadow-md":"bg-gray-100 text-gray-700 hover:bg-gray-200"),children:e},e))]})]})]}),s.jsx("div",{className:"mt-4 pt-4 border-t border-gray-200",children:s.jsxs("p",{className:"text-sm text-gray-600",children:[s.jsx("span",{className:"font-semibold text-gray-900",children:M.length})," ",1===M.length?"resultado encontrado":"resultados encontrados"]})})]}),I?s.jsxs("div",{className:"text-center py-12",children:[s.jsx("div",{className:"animate-spin rounded-full h-12 w-12 border-b-2 border-blue-600 mx-auto"}),s.jsx("p",{className:"text-gray-600 mt-4",children:"Carregando tabelas..."})]}):0===M.length?s.jsxs("div",{className:"bg-yellow-50 border border-yellow-200 rounded-xl p-8 text-center",children:[s.jsx("p",{className:"text-gray-700 mb-4",children:"Nenhuma tabela encontrada com os filtros selecionados."}),s.jsx("button",{onClick:z,className:"text-blue-600 hover:text-blue-700 font-medium underline",children:"Limpar filtros e ver todas"})]}):s.jsx("div",{className:"space-y-8",children:Object.entries(_).map(([e,t])=>s.jsxs("div",{children:[s.jsxs("h2",{className:"text-2xl font-bold text-gray-900 mb-4 flex items-center gap-2",children:[s.jsx(h,{className:"w-6 h-6 text-blue-600"}),e,s.jsxs("span",{className:"text-sm font-normal text-gray-500",children:["(",t.length," ",1===t.length?"tabela":"tabelas",")"]})]}),s.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-3 md:gap-4",children:t.map(e=>s.jsxs(a,{to:"/".concat(e.slug),className:"bg-white rounded-lg border border-gray-200 p-4 md:p-5 hover:shadow-lg hover:border-blue-300 transition-all duration-300 group",children:[s.jsx("h3",{className:"text-sm md:text-base font-semibold text-gray-900 mb-1.5 md:mb-2 group-hover:text-blue-600 transition-colors line-clamp-2",children:e.h1||e.title}),s.jsx("p",{className:"text-xs md:text-sm text-gray-600 mb-3 md:mb-4 line-clamp-2",children:e.meta_description}),s.jsxs("div",{className:"flex items-center justify-between",children:[s.jsx("div",{className:"flex flex-wrap gap-1.5 md:gap-2",children:e.localidade&&s.jsx("span",{className:"text-[10px] md:text-xs bg-purple-100 text-purple-700 px-2 py-0.5 md:py-1 rounded",children:e.localidade})}),s.jsx(g,{className:"w-4 md:w-5 h-4 md:h-5 text-gray-400 group-hover:text-blue-600 group-hover:translate-x-1 transition-all flex-shrink-0"})]})]},e.id))})]},e))})]}),s.jsxs("div",{className:"bg-gradient-to-r from-blue-600 to-blue-700 rounded-xl md:rounded-2xl shadow-xl p-6 md:p-8 mt-8 md:mt-12 text-white text-center",children:[s.jsx("h3",{className:"text-xl md:text-2xl font-bold mb-2 md:mb-3",children:"Não encontrou o que procura?"}),s.jsx("p",{className:"text-sm md:text-base text-blue-100 mb-5 md:mb-6 max-w-2xl mx-auto",children:"Nossa equipe pode ajudar você a encontrar o plano de saúde ideal com as melhores condições do mercado."}),s.jsxs("a",{href:"https://wa.me/5511959305175",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-white text-blue-600 font-semibold px-6 md:px-8 py-2.5 md:py-3 rounded-lg hover:bg-blue-50 transition-colors text-sm md:text-base",children:["Falar com Especialista",s.jsx(p,{className:"w-5 h-5"})]})]})]})})}),s.jsx(o,{})]})};export{v as default};