diff --git a/src/app/quote/page.tsx b/src/app/quote/page.tsx new file mode 100644 index 0000000..ef5a49b --- /dev/null +++ b/src/app/quote/page.tsx @@ -0,0 +1,129 @@ +"use client"; + +import React, { useState } from "react"; +import ReactLenis from "lenis/react"; +import NavbarLayoutFloatingInline from "@/components/navbar/NavbarLayoutFloatingInline"; +import { ThemeProvider } from "@/providers/themeProvider/ThemeProvider"; +import Input from "@/components/form/Input"; +import ButtonHoverBubble from "@/components/button/ButtonHoverBubble"; +import { Calculator } from "lucide-react"; + +export default function QuoteCalculatorPage() { + const [departurePort, setDeparturePort] = useState(""); + const [arrivalPort, setArrivalPort] = useState(""); + const [cargoType, setCargoType] = useState(""); + const [weight, setWeight] = useState(""); + const [volume, setVolume] = useState(""); + const [shippingOption, setShippingOption] = useState(""); // 'Charter' or 'Line' + const [costEstimate, setCostEstimate] = useState(null); + + const handleCalculateQuote = () => { + // Placeholder for actual calculation logic + // In a real application, this would involve API calls or complex calculations + const baseCost = 1000; + const weightFactor = parseFloat(weight || "0") * 5; + const volumeFactor = parseFloat(volume || "0") * 10; + const typeFactor = cargoType.toLowerCase().includes("container") ? 200 : 100; + const optionFactor = shippingOption.toLowerCase() === "charter" ? 1.5 : 1; + + const totalEstimate = (baseCost + weightFactor + volumeFactor + typeFactor) * optionFactor; + setCostEstimate(`$${totalEstimate.toFixed(2)}`); + }; + + return ( + + + +
+
+ +

Instant Shipping Quote Calculator

+

+ Get an instant estimate for your maritime cargo. Select your ports, cargo details, and service type for a quick cost overview. +

+
+ + + + + + {/* Using Input as a placeholder for a select dropdown for simplicity */} + + + {costEstimate && ( +
+ Estimated Cost: {costEstimate} +
+ )} + +
+
+
+
+
+ ); +}