%PDF- %PDF-
| Direktori : /home/vacivi36/.trash/vacivitta/src/pages/ |
| Current File : /home/vacivi36/.trash/vacivitta/src/pages/FaleConosco.jsx |
import React, { useState } from 'react';
import styled, { keyframes } from 'styled-components';
import { motion, AnimatePresence } from 'framer-motion';
import { FaWhatsapp, FaPhone, FaEnvelope, FaMapMarkerAlt, FaUser, FaClock, FaArrowRight, FaChevronDown, FaChevronUp } from 'react-icons/fa';
// Animations
const fadeIn = keyframes`
from { opacity: 0; }
to { opacity: 1; }
`;
const floatAnimation = keyframes`
0% { transform: translateY(0px); }
50% { transform: translateY(-8px); }
100% { transform: translateY(0px); }
`;
const PageContainer = styled.div`
margin-top: 100px;
padding-bottom: 60px;
max-width: 1200px;
margin-left: auto;
margin-right: auto;
`;
// Hero Section
const HeroSection = styled.section`
background: linear-gradient(to right, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.7)), url('/homePage.png');
background-size: cover;
background-position: center;
padding: 80px 60px;
text-align: center;
border-radius: 16px;
margin: 0 20px 40px;
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
@media (max-width: 768px) {
padding: 60px 20px;
margin: 0 10px 30px;
}
`;
const HeroTitle = styled(motion.h1)`
color: #0094d9;
font-size: 2.5rem;
margin-bottom: 20px;
line-height: 1.2;
@media (max-width: 768px) {
font-size: 2rem;
}
`;
const HeroSubtitle = styled(motion.p)`
color: #333;
font-size: 1.2rem;
margin-bottom: 15px;
line-height: 1.6;
max-width: 800px;
margin-left: auto;
margin-right: auto;
@media (max-width: 768px) {
font-size: 1rem;
}
`;
const HeroCTA = styled(motion.p)`
color: #3d9948;
font-size: 1.3rem;
font-weight: 600;
animation: ${fadeIn} 1s ease-in-out;
@media (max-width: 768px) {
font-size: 1.1rem;
}
`;
// Section Components
const Section = styled.section`
background: white;
border-radius: 16px;
padding: 40px;
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
margin: 0 20px 40px;
@media (max-width: 768px) {
padding: 30px 20px;
margin: 0 10px 30px;
}
`;
const SectionTitle = styled.h2`
color: #0094d9;
font-size: 2rem;
text-align: center;
margin-bottom: 30px;
@media (max-width: 768px) {
font-size: 1.7rem;
}
`;
const SectionDescription = styled.p`
color: #555;
text-align: center;
margin-bottom: 30px;
max-width: 800px;
margin-left: auto;
margin-right: auto;
line-height: 1.6;
`;
// Form Section
const FormGrid = styled.div`
display: grid;
grid-template-columns: 1fr 1fr;
gap: 20px;
@media (max-width: 768px) {
grid-template-columns: 1fr;
}
`;
const FormGroup = styled.div`
margin-bottom: 20px;
`;
const FormLabel = styled.label`
display: block;
margin-bottom: 8px;
color: #333;
font-weight: 500;
`;
const FormInput = styled.input`
width: 100%;
padding: 12px 15px;
border: 1px solid #ddd;
border-radius: 8px;
font-size: 16px;
transition: all 0.3s;
&:focus {
outline: none;
border-color: #0094d9;
box-shadow: 0 0 0 3px rgba(0, 148, 217, 0.1);
}
`;
const FormSelect = styled.select`
width: 100%;
padding: 12px 15px;
border: 1px solid #ddd;
border-radius: 8px;
font-size: 16px;
background-color: white;
transition: all 0.3s;
&:focus {
outline: none;
border-color: #0094d9;
box-shadow: 0 0 0 3px rgba(0, 148, 217, 0.1);
}
`;
const FormTextarea = styled.textarea`
width: 100%;
padding: 12px 15px;
border: 1px solid #ddd;
border-radius: 8px;
font-size: 16px;
min-height: 120px;
transition: all 0.3s;
grid-column: 1 / 3;
&:focus {
outline: none;
border-color: #0094d9;
box-shadow: 0 0 0 3px rgba(0, 148, 217, 0.1);
}
@media (max-width: 768px) {
grid-column: 1;
}
`;
const SubmitButton = styled.button`
background-color: #0094d9;
color: white;
border: none;
padding: 12px 24px;
border-radius: 50px;
font-size: 16px;
font-weight: 600;
cursor: pointer;
transition: all 0.3s ease;
display: flex;
align-items: center;
justify-content: center;
gap: 8px;
margin: 20px auto 0;
&:hover {
background-color: #3d9948;
transform: translateY(-3px);
box-shadow: 0 5px 15px rgba(0, 148, 217, 0.3);
}
`;
// Contact Channels Section
const ChannelsGrid = styled.div`
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 20px;
@media (max-width: 992px) {
grid-template-columns: repeat(2, 1fr);
}
@media (max-width: 768px) {
grid-template-columns: 1fr;
}
`;
const ChannelCard = styled.div`
background: #f9f9f9;
border-radius: 12px;
padding: 25px;
text-align: center;
transition: transform 0.3s ease, box-shadow 0.3s ease;
&:hover {
transform: translateY(-5px);
box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}
`;
const ChannelIcon = styled.div`
width: 70px;
height: 70px;
background-color: #0094d9;
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
margin: 0 auto 15px;
color: white;
font-size: 28px;
`;
const ChannelTitle = styled.h3`
color: #333;
margin-bottom: 10px;
`;
const ChannelText = styled.p`
color: #666;
margin-bottom: 5px;
`;
const ChannelLink = styled.a`
color: #0094d9;
text-decoration: none;
transition: color 0.3s;
display: inline-block;
margin-top: 10px;
font-weight: 500;
&:hover {
color: #3d9948;
}
`;
// Location Section
const LocationFlex = styled.div`
display: flex;
flex-direction: column;
align-items: center;
`;
const MapContainer = styled.div`
width: 100%;
height: 400px;
border-radius: 12px;
overflow: hidden;
margin-top: 30px;
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
iframe {
width: 100%;
height: 100%;
border: 0;
}
`;
const AddressCard = styled.div`
background: #f9f9f9;
border-radius: 12px;
padding: 20px;
margin-bottom: 30px;
display: flex;
align-items: center;
max-width: 600px;
box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
`;
const AddressIcon = styled.div`
width: 50px;
height: 50px;
background-color: #0094d9;
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
margin-right: 20px;
color: white;
font-size: 20px;
flex-shrink: 0;
`;
const AddressText = styled.div`
h3 {
color: #333;
margin-bottom: 5px;
}
p {
color: #666;
margin: 0;
line-height: 1.5;
}
`;
// FAQ Section
const FAQList = styled.div`
max-width: 800px;
margin: 0 auto;
`;
const FAQItem = styled.div`
margin-bottom: 15px;
border-radius: 12px;
overflow: hidden;
box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
`;
const FAQQuestion = styled.div`
padding: 15px 20px;
cursor: pointer;
font-weight: 600;
background: #0094d9;
color: white;
display: flex;
justify-content: space-between;
align-items: center;
&:hover {
background: #0085c7;
}
`;
const FAQAnswer = styled(motion.div)`
padding: 0;
background: #f9f9f9;
overflow: hidden;
`;
const FAQAnswerContent = styled.div`
padding: 20px;
color: #666;
line-height: 1.6;
`;
// Callback Section
const CallbackSection = styled(Section)`
background: linear-gradient(135deg, #0094d9 0%, #3d9948 100%);
color: white;
`;
const CallbackForm = styled.form`
display: grid;
grid-template-columns: 1fr 1fr;
gap: 20px;
max-width: 800px;
margin: 0 auto;
@media (max-width: 768px) {
grid-template-columns: 1fr;
}
`;
const CallbackInput = styled.input`
padding: 12px 15px;
border: none;
border-radius: 8px;
font-size: 16px;
width: 100%;
&:focus {
outline: none;
box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.2);
}
`;
const CallbackSelect = styled.select`
padding: 12px 15px;
border: none;
border-radius: 8px;
font-size: 16px;
background-color: white;
width: 100%;
&:focus {
outline: none;
box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.2);
}
`;
const CallbackButton = styled(SubmitButton)`
background-color: white;
color: #0094d9;
margin-top: 20px;
grid-column: 1 / 3;
&:hover {
background-color: #f0f0f0;
color: #3d9948;
}
@media (max-width: 768px) {
grid-column: 1;
}
`;
// Footer CTA
const FooterCTA = styled.div`
text-align: center;
padding: 40px 20px;
h2 {
color: #0094d9;
margin-bottom: 15px;
font-size: 1.8rem;
}
p {
color: #333;
margin-bottom: 20px;
font-size: 1.1rem;
}
`;
const SocialButtons = styled.div`
display: flex;
justify-content: center;
gap: 20px;
margin-top: 30px;
`;
const SocialButton = styled.a`
width: 60px;
height: 60px;
border-radius: 50%;
background-color: #0094d9;
display: flex;
align-items: center;
justify-content: center;
color: white;
font-size: 24px;
transition: all 0.3s ease;
&:hover {
background-color: #3d9948;
transform: translateY(-5px);
box-shadow: 0 5px 15px rgba(0, 148, 217, 0.3);
}
`;
function FaleConosco() {
const [formData, setFormData] = useState({
name: '',
email: '',
phone: '',
subject: '',
unit: '',
message: ''
});
const [callbackData, setCallbackData] = useState({
name: '',
phone: '',
time: '',
subject: '',
unit: ''
});
const [activeFAQ, setActiveFAQ] = useState(null);
// List of units with their respective emails
const units = [
{ name: "Itu - SP", email: "itu@vacivitta.com.br" },
{ name: "Salto - SP", email: "salto@vacivitta.com.br" },
{ name: "Indaiatuba - SP", email: "indaiatuba@vacivitta.com.br" },
{ name: "Santos - SP", email: "santos@vacivitta.com.br" },
{ name: "Itanhaém - SP", email: "itanhaem@vacivitta.com.br" },
{ name: "São Paulo - SP", email: "paraiso@vacivitta.com.br" },
{ name: "Anápolis - GO", email: "anapolis@vacivitta.com.br" },
{ name: "Brasília - DF", email: "brasilia@vacivitta.com.br" },
{ name: "Barra - RJ", email: "barra@vacivitta.com.br" },
{ name: "Campinas - SP", email: "campinas@vacivitta.com.br" },
{ name: "Paulínia - SP", email: "paulinia@vacivitta.com.br" },
{ name: "Sorocaba - SP", email: "sorocaba@vacivitta.com.br" },
{ name: "Curitiba - PR", email: "curitiba@vacivitta.com.br" }
];
const handleFormChange = (e) => {
setFormData({
...formData,
[e.target.name]: e.target.value
});
};
const handleCallbackChange = (e) => {
setCallbackData({
...callbackData,
[e.target.name]: e.target.value
});
};
const handleFormSubmit = (e) => {
e.preventDefault();
// Get the selected unit's email
const selectedUnit = units.find(unit => unit.name === formData.unit);
const targetEmail = selectedUnit ? selectedUnit.email : "atendimento@vacivitta.com.br";
// Logic for form submission
console.log("Form submitted to:", targetEmail, formData);
alert("Mensagem enviada com sucesso! Entraremos em contato em breve.");
setFormData({
name: '',
email: '',
phone: '',
subject: '',
unit: '',
message: ''
});
};
const handleCallbackSubmit = (e) => {
e.preventDefault();
// Get the selected unit's email
const selectedUnit = units.find(unit => unit.name === callbackData.unit);
const targetEmail = selectedUnit ? selectedUnit.email : "atendimento@vacivitta.com.br";
// Logic for callback form submission
console.log("Callback requested to:", targetEmail, callbackData);
alert("Solicitação de retorno recebida! Entraremos em contato em breve.");
setCallbackData({
name: '',
phone: '',
time: '',
subject: '',
unit: ''
});
};
const toggleFAQ = (index) => {
setActiveFAQ(activeFAQ === index ? null : index);
};
const faqs = [
{
question: "Quais os horários de funcionamento?",
answer: "Segunda a Sexta, das 8h às 18h."
},
{
question: "Preciso de agendamento para realizar exames?",
answer: "Sim, recomendamos que você agende previamente para garantir o atendimento."
},
{
question: "Vocês atendem empresas?",
answer: "Sim, oferecemos serviços de vacinação e exames corporativos."
},
{
question: "Posso cancelar ou remarcar meu agendamento?",
answer: "Sim, entre em contato conosco pelo WhatsApp ou telefone para remarcar ou cancelar."
}
];
return (
<PageContainer>
{/* Hero Section */}
<HeroSection>
<HeroTitle
initial={{ opacity: 0, y: -20 }}
animate={{ opacity: 1, y: 0 }}
transition={{ duration: 0.5 }}
>
Estamos aqui para ajudar, entre em contato conosco!
</HeroTitle>
<HeroSubtitle
initial={{ opacity: 0, y: -20 }}
animate={{ opacity: 1, y: 0 }}
transition={{ duration: 0.5, delay: 0.2 }}
>
Tire suas dúvidas, agende serviços ou fale diretamente com nossa equipe.
</HeroSubtitle>
<HeroCTA>Envie sua mensagem agora mesmo!</HeroCTA>
</HeroSection>
{/* Contact Form Section */}
<Section>
<SectionTitle>Formulário de contato</SectionTitle>
<SectionDescription>
Entre em contato com a Vacivitta de forma simples e rápida, preenchendo o formulário abaixo.
Nossa equipe está pronta para responder todas as suas dúvidas ou agendar serviços.
</SectionDescription>
<form onSubmit={handleFormSubmit}>
<FormGrid>
<FormGroup>
<FormLabel>Nome completo</FormLabel>
<FormInput
type="text"
name="name"
value={formData.name}
onChange={handleFormChange}
placeholder="Para identificarmos você"
required
/>
</FormGroup>
<FormGroup>
<FormLabel>Email</FormLabel>
<FormInput
type="email"
name="email"
value={formData.email}
onChange={handleFormChange}
placeholder="Para retorno da nossa equipe"
required
/>
</FormGroup>
<FormGroup>
<FormLabel>Telefone</FormLabel>
<FormInput
type="tel"
name="phone"
value={formData.phone}
onChange={handleFormChange}
placeholder="Caso prefira contato direto"
/>
</FormGroup>
<FormGroup>
<FormLabel>Assunto</FormLabel>
<FormSelect
name="subject"
value={formData.subject}
onChange={handleFormChange}
required
>
<option value="">Selecione o assunto</option>
<option value="Exames">Exames</option>
<option value="Vacinação">Vacinação</option>
<option value="Orçamento">Orçamento</option>
<option value="Dúvidas Gerais">Dúvidas gerais</option>
</FormSelect>
</FormGroup>
<FormGroup>
<FormLabel>Unidade</FormLabel>
<FormSelect
name="unit"
value={formData.unit}
onChange={handleFormChange}
required
>
<option value="">Selecione a unidade</option>
{units.map((unit, index) => (
<option key={index} value={unit.name}>{unit.name}</option>
))}
</FormSelect>
</FormGroup>
<FormTextarea
name="message"
value={formData.message}
onChange={handleFormChange}
placeholder="Espaço para detalhar sua solicitação ou dúvida"
required
/>
</FormGrid>
<SubmitButton type="submit">
Enviar Mensagem <FaArrowRight />
</SubmitButton>
</form>
</Section>
{/* Contact Channels Section */}
<Section>
<SectionTitle>Canais de Atendimento</SectionTitle>
<SectionDescription>
Além do formulário, você pode nos contatar pelos canais abaixo:
</SectionDescription>
<ChannelsGrid>
<ChannelCard>
<ChannelIcon>
<FaWhatsapp />
</ChannelIcon>
<ChannelTitle>WhatsApp</ChannelTitle>
<ChannelText>Atendimento rápido via mensagem</ChannelText>
<ChannelText>Segunda a Sexta, das 8h às 18h</ChannelText>
<ChannelLink href="https://wa.me/551108001233333" target="_blank" rel="noopener noreferrer">
Iniciar conversa
</ChannelLink>
</ChannelCard>
<ChannelCard>
<ChannelIcon>
<FaPhone />
</ChannelIcon>
<ChannelTitle>Telefone</ChannelTitle>
<ChannelText>Atendimento ao cliente</ChannelText>
<ChannelText>Segunda a Sexta, das 8h às 18h</ChannelText>
<ChannelLink href="tel:+551108001233333">
0800 123 3333
</ChannelLink>
</ChannelCard>
<ChannelCard>
<ChannelIcon>
<FaEnvelope />
</ChannelIcon>
<ChannelTitle>Email</ChannelTitle>
<ChannelText>Para contato mais detalhado</ChannelText>
<ChannelLink href="mailto:atendimento@vacivitta.com.br">
atendimento@vacivitta.com.br
</ChannelLink>
</ChannelCard>
</ChannelsGrid>
</Section>
{/* Callback Section */}
<CallbackSection>
<SectionTitle style={{ color: 'white' }}>Podemos te ligar?</SectionTitle>
<SectionDescription style={{ color: 'rgba(255, 255, 255, 0.8)' }}>
Preencha suas informações e nossa equipe retornará a ligação em breve.
</SectionDescription>
<CallbackForm onSubmit={handleCallbackSubmit}>
<CallbackInput
type="text"
name="name"
value={callbackData.name}
onChange={handleCallbackChange}
placeholder="Seu nome"
required
/>
<CallbackInput
type="tel"
name="phone"
value={callbackData.phone}
onChange={handleCallbackChange}
placeholder="Seu telefone"
required
/>
<CallbackSelect
name="time"
value={callbackData.time}
onChange={handleCallbackChange}
required
>
<option value="">Horário preferido para ligação</option>
<option value="Manhã">Manhã (8h às 12h)</option>
<option value="Tarde">Tarde (12h às 18h)</option>
</CallbackSelect>
<CallbackSelect
name="subject"
value={callbackData.subject}
onChange={handleCallbackChange}
required
>
<option value="">Assunto</option>
<option value="Exames">Exames</option>
<option value="Vacinação">Vacinação</option>
<option value="Orçamento">Orçamento</option>
<option value="Dúvidas Gerais">Dúvidas Gerais</option>
</CallbackSelect>
<CallbackSelect
name="unit"
value={callbackData.unit}
onChange={handleCallbackChange}
required
>
<option value="">Selecione a unidade</option>
{units.map((unit, index) => (
<option key={index} value={unit.name}>{unit.name}</option>
))}
</CallbackSelect>
<CallbackButton type="submit">
Enviar Solicitação de Retorno <FaArrowRight />
</CallbackButton>
</CallbackForm>
</CallbackSection>
{/* Footer CTA */}
<FooterCTA>
<h2>Entre em contato com a Vacivitta e tenha o suporte que você precisa</h2>
<p>Estamos prontos para atender você!</p>
<SocialButtons>
<SocialButton href="https://wa.me/551108001233333" target="_blank" rel="noopener noreferrer">
<FaWhatsapp />
</SocialButton>
<SocialButton href="tel:+551108001233333">
<FaPhone />
</SocialButton>
<SocialButton href="mailto:atendimento@vacivitta.com.br">
<FaEnvelope />
</SocialButton>
</SocialButtons>
</FooterCTA>
</PageContainer>
);
}
export default FaleConosco;