From 0108118f2cd20ebb1dcab95b4a43adc740a78437 Mon Sep 17 00:00:00 2001 From: akash Date: Sat, 14 Mar 2026 22:22:23 +0530 Subject: [PATCH] contact poup updated in carees page --- src/app/blog/page.tsx | 4 +- src/app/careers/page.tsx | 4 +- src/app/globals.css | 369 ++++++++++++------ .../careers/CareersContactPopup.tsx | 46 ++- src/components/careers/CareersForm.tsx | 351 ----------------- src/components/careers/ContactSection.tsx | 23 +- src/components/faq/FaqPageSection.tsx | 2 +- src/components/home/ProjectsSection.tsx | 23 +- 8 files changed, 308 insertions(+), 514 deletions(-) delete mode 100644 src/components/careers/CareersForm.tsx diff --git a/src/app/blog/page.tsx b/src/app/blog/page.tsx index ee1a836..48b98d1 100644 --- a/src/app/blog/page.tsx +++ b/src/app/blog/page.tsx @@ -7,8 +7,8 @@ import PageHeader from "@/components/common/PageHeader"; import MetatronInitializer from "@/components/MetatronInitializer"; export const metadata: Metadata = { - title: "Top 5 SEO Trends for 2025 | Metatroncube", - description: "Explore the latest SEO strategies for 2025. Stay ahead with insights from Metatroncube Software Solution.", + title: "Web Dev, SEO & Digital Marketing Blog | Metatroncube", + description: "Expert insights on web development, SEO strategies, and digital marketing trends. Actionable tips from Metatroncube Software Solutions in Waterloo, Canada.", alternates: { canonical: "/blog", }, diff --git a/src/app/careers/page.tsx b/src/app/careers/page.tsx index 08e6886..05b53e5 100644 --- a/src/app/careers/page.tsx +++ b/src/app/careers/page.tsx @@ -8,7 +8,7 @@ import AboutService from "@/components/services-digital-solutions/AboutService"; import AboutThree from "@/components/home/AboutThree"; import ProjectsSection from "@/components/home/ProjectsSection"; import MetatronInitializer from "@/components/MetatronInitializer"; -import CareersForm from "@/components/careers/CareersForm"; + export const metadata: Metadata = { title: "Careers - Metatroncube Software Solution | Innovative & User-Centric Tech Services in Waterloo", @@ -33,7 +33,7 @@ export default function CareersPage() { - {/* */} + diff --git a/src/app/globals.css b/src/app/globals.css index 0776606..94013d4 100644 --- a/src/app/globals.css +++ b/src/app/globals.css @@ -6841,7 +6841,7 @@ body { .faq-one__accordion .accrodion { margin-bottom: 25px; - border-radius: 70px; + border-radius: 10px; border: 1px solid var(--pelocis-border-color, #DDDDDD); overflow: hidden; transition: all 400ms ease; @@ -6921,10 +6921,14 @@ body { color: var(--pelocis-white, #fff); font-size: 10px; transition: all 400ms ease; + opacity: 0; + visibility: hidden; } .faq-one__accordion .active .accrodion-title__icon { background-color: var(--pelocis-base, #3779b9); + opacity: 1; + visibility: visible; } .faq-one__accordion .accrodion-content .inner { @@ -9307,46 +9311,58 @@ body { box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2); } -.form-label-custom-global { +.form-label-custom-global, +.form-label-custom { display: block; margin-bottom: 8px; font-weight: 700; color: #fff; font-size: 14px; letter-spacing: 0.5px; + text-transform: uppercase; } .form-input-custom-global, .form-textarea-custom-global, -.form-select-custom-styled-global { +.form-select-custom-styled-global, +.form-input, +.form-select, +.form-textarea { width: 100%; - padding: 18px 25px; - border: 1px solid #e2e8f0; - background-color: #fff; + padding: 15px 20px; + border: 1px solid rgba(255, 255, 255, 0.1); + background-color: rgba(255, 255, 255, 0.05); border-radius: 12px; outline: none; font-size: 15px; - color: #1e293b; + color: #fff; transition: all 0.3s ease; + height: 60px; } -.form-textarea-custom-global { - min-height: 120px; +.form-textarea-custom-global, +.form-textarea { + min-height: 100px; + height: auto; resize: vertical; } .form-input-custom-global:focus, .form-textarea-custom-global:focus, -.form-select-custom-styled-global:focus { +.form-select-custom-styled-global:focus, +.form-input:focus, +.form-textarea:focus, +.form-select:focus { border-color: #3779b9; - box-shadow: 0 0 0 4px rgba(55, 121, 185, 0.1); + background-color: rgba(255, 255, 255, 0.08); + box-shadow: 0 0 0 4px rgba(55, 121, 185, 0.15); } .submit-btn-custom-global { width: 100%; background: #3779b9 !important; color: #fff !important; - padding: 20px 30px; + padding: 18px 30px; border: none; border-radius: 12px; font-weight: 700; @@ -9355,7 +9371,12 @@ body { text-transform: uppercase; letter-spacing: 1.5px; font-size: 17px; - box-shadow: 0 10px 20px rgba(99, 102, 241, 0.2); + box-shadow: 0 10px 20px rgba(55, 121, 185, 0.2); + height: 60px; + display: flex; + align-items: center; + justify-content: center; + gap: 10px; } .submit-btn-custom-global:hover { @@ -16449,7 +16470,7 @@ h4.service-details__dynamic-content-erp { padding: 18px 24px; cursor: pointer; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); - min-height: 70px; + min-height: 40px; position: relative; overflow: hidden; } @@ -17346,9 +17367,6 @@ h4.service-details__dynamic-content-erp { } .careers-popup-optimized .file-content { - display: flex; - align-items: center; - gap: 10px; color: rgba(255, 255, 255, 0.6); } @@ -17367,8 +17385,9 @@ h4.service-details__dynamic-content-erp { .careers-popup-optimized .form-panel { padding: 30px 45px 25px !important; background: #1a1f2b !important; - overflow: hidden !important; - /* Force no scroll on panel */ + overflow-y: auto !important; + /* Allow internal scroll if needed as fallback */ + max-height: calc(100vh - 40px); } .careers-popup-optimized .form-header { @@ -17463,9 +17482,6 @@ h4.service-details__dynamic-content-erp { } .careers-popup-optimized .file-content { - display: flex; - align-items: center; - gap: 10px; color: rgba(255, 255, 255, 0.6); } @@ -17552,125 +17568,240 @@ h4.service-details__dynamic-content-erp { .careers-popup-optimized { max-width: 600px !important; width: 90% !important; + max-height: 95vh !important; + overflow-y: auto !important; } + /* No-scroll optimization: compress vertical rhythm */ .careers-popup-optimized .form-panel { - padding: 15px 30px 10px !important; + padding: 10px 20px 10px !important; } .careers-popup-optimized .form-header { - margin-bottom: 15px; - } - - .careers-popup-optimized .form-input { - padding: 10px 14px !important; - } - - .careers-popup-optimized .form-textarea { - min-height: 60px !important; - } - - .careers-popup-optimized .g-recaptcha-container { - transform: scale(0.8); - margin: 5px 0 !important; - } - - .contact-popup-content .close-btn { - position: absolute; - top: 10px !important; - right: 10px !important; - background: #f3f4f6; - border: none; - width: 25px !important; - height: 25px !important; - border-radius: 50%; - font-size: 16px !important; - cursor: pointer; - color: #1a1f2b; - display: flex; - align-items: center; - justify-content: center; - transition: all 0.3s; - z-index: 100; - } -} - -/* 500-475px */ -@media (max-width: 500px) { - .careers-popup-optimized { - width: 95% !important; - } - - .careers-popup-optimized .form-panel { - padding: 12px 20px 8px !important; + margin-bottom: 5px !important; } .careers-popup-optimized .form-title { font-size: 20px !important; } - .careers-popup-optimized .form-subtitle { - font-size: 12px !important; - } - - .careers-popup-optimized .form-label-custom { - font-size: 9px !important; - margin-bottom: 3px; - } - - .careers-popup-optimized .mt-3 { - margin-top: 8px !important; - } -} - -/* 425px */ -@media (max-width: 425px) { - .careers-popup-optimized .form-panel { - padding: 10px 15px 5px !important; - } - - .careers-popup-optimized .g-recaptcha-container { - transform: scale(0.75); - } -} - -/* 320px - Small Mobile */ -@media (max-width: 320px) { - .careers-popup-optimized .form-panel { - padding: 8px 12px 5px !important; - } - - .careers-popup-optimized .form-title { - font-size: 18px !important; - } - - .careers-popup-optimized .form-subtitle { - display: none; - } - - .careers-popup-optimized .form-label-custom { - display: none; - } - - /* Hide labels, placeholders only to save vertical space */ - .careers-popup-optimized .form-input { - padding: 8px 12px !important; - font-size: 12px !important; + .careers-popup-optimized .form-input, + .careers-popup-optimized .form-select, + .careers-popup-optimized .form-textarea { + height: 33px !important; + padding: 8px 15px !important; + font-size: 14px !important; } .careers-popup-optimized .form-textarea { min-height: 50px !important; - font-size: 12px !important; } .careers-popup-optimized .g-recaptcha-container { - transform: scale(0.65); - margin: 3px 0 !important; + transform: scale(0.7) !important; + margin: 0 !important; + height: 60px !important; + overflow: hidden !important; } .careers-popup-optimized .submit-btn { - padding: 12px !important; - font-size: 13px !important; + height: 50px !important; margin-top: 5px !important; } +} + +/* 500-320px - Mobile */ +@media (max-width: 500px) { + .careers-popup-optimized { + width: 95% !important; + max-height: 98vh !important; + } + + .careers-popup-optimized .form-panel { + padding: 8px 15px 5px !important; + } + + .careers-popup-optimized .form-label-custom { + font-size: 11px !important; + margin-bottom: 2px !important; + } + + .careers-popup-optimized .row.g-3 { + --bs-gutter-y: 8px !important; + } + + .careers-popup-optimized .mt-3 { + margin-top: 5px !important; + } + + .careers-popup-optimized .file-upload-styled { + margin-bottom: 5px !important; + } + + .careers-popup-optimized .file-browse-btn { + padding: 4px 10px !important; + font-size: 12px !important; + } +} + +.careers-popup-optimized .form-textarea { + min-height: 50px !important; + font-size: 12px !important; + color: #fff; +} + +.careers-popup-optimized .g-recaptcha-container { + transform: scale(0.65); + margin: 3px 0 !important; +} + +.careers-popup-optimized .submit-btn { + padding: 12px !important; + font-size: 13px !important; + margin-top: 5px !important; +} + +/* ── Height Based Responsiveness (No-Scroll Optimization) ── */ +@media (max-height: 600px) { + .careers-popup-optimized .form-panel { + padding: 8px 15px 5px !important; + } + + .careers-popup-optimized .form-header { + margin-bottom: 5px !important; + } + + .careers-popup-optimized .form-title { + font-size: 16px !important; + } + + .careers-popup-optimized .form-label-custom { + font-size: 9px !important; + margin-bottom: 2px !important; + } + + .careers-popup-optimized .form-input, + .careers-popup-optimized .form-select { + height: 36px !important; + padding: 4px 10px !important; + font-size: 13px !important; + } + + .careers-popup-optimized .form-textarea { + min-height: 36px !important; + height: 36px !important; + padding: 5px 10px !important; + } + + .careers-popup-optimized .file-upload-label { + padding: 4px 10px !important; + } + + .careers-popup-optimized .file-browse-btn { + padding: 2px 8px !important; + font-size: 10px !important; + } + + .careers-popup-optimized .g-recaptcha-container { + transform: scale(0.6) !important; + transform-origin: center center; + height: 48px !important; + margin: 2px 0 !important; + } + + .careers-popup-optimized .submit-btn { + height: 38px !important; + margin-top: 5px !important; + font-size: 11px !important; + padding: 5px !important; + } +} + +@media (max-height: 500px) { + .careers-popup-optimized { + border-radius: 12px !important; + } + + .careers-popup-optimized .form-panel { + padding: 2px 10px 2px !important; + } + + .careers-popup-optimized .form-header { + margin-bottom: 2px !important; + } + + .careers-popup-optimized .form-title { + font-size: 14px !important; + } + + .careers-popup-optimized .form-label-custom { + font-size: 8px !important; + margin-bottom: 0 !important; + } + + .careers-popup-optimized .form-input, + .careers-popup-optimized .form-select, + .careers-popup-optimized .form-textarea { + height: 30px !important; + min-height: 30px !important; + padding: 2px 8px !important; + font-size: 11px !important; + } + + .careers-popup-optimized .mt-3, + .careers-popup-optimized .mt-1 { + margin-top: 2px !important; + } + + .careers-popup-optimized .file-upload-label { + padding: 2px 8px !important; + border-width: 1px !important; + } + + .careers-popup-optimized .file-content i { + font-size: 10px !important; + } + + .careers-popup-optimized .file-name-text { + font-size: 10px !important; + } + + .careers-popup-optimized .file-browse-btn { + padding: 2px 6px !important; + font-size: 9px !important; + } + + .careers-popup-optimized .g-recaptcha-container { + transform: scale(0.5) !important; + height: 38px !important; + margin: 1px 0 !important; + } + + .careers-popup-optimized .submit-btn { + height: 32px !important; + margin-top: 2px !important; + font-size: 10px !important; + padding: 0 !important; + } + + /* Extreme optimization: hide labels for optional fields to save space */ + .careers-popup-optimized .form-field-wrapper .form-label-custom { + display: none; + } + + .careers-popup-optimized .optional-label { + display: none; + } +} + +@media (max-height: 400px) { + .careers-popup-optimized .form-header { + display: none; + /* Hide header on very short screens to save space */ + } + + .careers-popup-optimized .form-panel { + padding-top: 20px !important; + /* Room for close btn */ + } } \ No newline at end of file diff --git a/src/components/careers/CareersContactPopup.tsx b/src/components/careers/CareersContactPopup.tsx index 41a7fa5..20062a3 100644 --- a/src/components/careers/CareersContactPopup.tsx +++ b/src/components/careers/CareersContactPopup.tsx @@ -12,13 +12,9 @@ interface CareersContactPopupProps { } const positions = [ - { value: "Frontend Developer", label: "Website Development" }, - { value: "Backend Developer", label: "Social Media Marketing" }, - { value: "Full Stack Developer", label: "Search Engine Optimization" }, - { value: "UI/UX Designer", label: "Mobile App Development" }, - { value: "SEO Specialist", label: "UI/UX Designing" }, - { value: "Digital Marketing Executive", label: "Graphic Designing" }, - { value: "Other", label: "Other" }, + { value: "Website Development", label: "Website Development" }, + { value: "Social Media Marketing", label: "Social Media Marketing" }, + { value: "Search Engine Optimization (SEO)", label: "Search Engine Optimization (SEO)" }, ]; const CareersContactPopup: React.FC = ({ @@ -26,12 +22,25 @@ const CareersContactPopup: React.FC = ({ onClose, defaultPosition = "", }) => { + // Helper to find match in positions array + const getMatchedPosition = (val: string) => { + if (!val) return ""; + const searchStr = val.toLowerCase(); + const found = positions.find(p => + p.label.toLowerCase() === searchStr || + p.value.toLowerCase() === searchStr || + searchStr.includes(p.label.toLowerCase()) || + p.label.toLowerCase().includes(searchStr) + ); + return found ? found.value : val; + }; + const [mounted, setMounted] = useState(false); const [formData, setFormData] = useState({ name: "", email: "", phone: "", - position: defaultPosition, + position: getMatchedPosition(defaultPosition), message: "", }); const [resumeFile, setResumeFile] = useState(null); @@ -48,7 +57,9 @@ const CareersContactPopup: React.FC = ({ // Sync position when defaultPosition changes (new card clicked) useEffect(() => { - setFormData((prev) => ({ ...prev, position: defaultPosition })); + if (defaultPosition) { + setFormData((prev) => ({ ...prev, position: getMatchedPosition(defaultPosition) })); + } }, [defaultPosition]); // Close on ESC @@ -127,17 +138,21 @@ const CareersContactPopup: React.FC = ({ email: formData.email, phone: formData.phone, position: formData.position, - message: `Position: ${formData.position}

Phone: ${formData.phone}

Message: ${formData.message || "No additional message."}`, + message: `Full Name: ${formData.name}
Email Address: ${formData.email}
Phone Number: ${formData.phone}
Position: ${formData.position}

Message: ${formData.message || "No additional message."}${resumeFile ? `

Resume attached: ${resumeFile.name}` : ""}`, to: "info@metatroncubesolutions.com", senderName: "Metatroncube Careers Application", recaptchaToken: captchaToken, }; if (resumeBase64 && resumeFile) { + // Extract raw base64 from data URI + const base64Content = resumeBase64.split(",")[1]; emailData.attachments = [ { filename: resumeFile.name, - path: resumeBase64, + content: base64Content, + contentType: resumeFile.type, + encoding: 'base64', }, ]; } @@ -178,7 +193,7 @@ const CareersContactPopup: React.FC = ({ }, [alert.show]); const handleReset = () => { - setFormData({ name: "", email: "", phone: "", position: defaultPosition, message: "" }); + setFormData({ name: "", email: "", phone: "", position: getMatchedPosition(defaultPosition), message: "" }); setResumeFile(null); setResumeBase64(null); if (fileInputRef.current) fileInputRef.current.value = ""; @@ -275,7 +290,12 @@ const CareersContactPopup: React.FC = ({ > {positions - .filter(pos => !defaultPosition || pos.value === defaultPosition) + .filter(pos => !defaultPosition || + pos.label === defaultPosition || + pos.value === defaultPosition || + defaultPosition.toLowerCase().includes(pos.label.toLowerCase()) || + pos.label.toLowerCase().includes(defaultPosition.toLowerCase()) + ) .map((pos) => (