import{u as g,r as c,j as e,E as r,a as l,b as j,c as p,B as C,P as w,d as y,e as v,F as b,f as S}from"./index-BTeXlNCi.js";import{B as k}from"./BookingForm-BU_f2ekq.js";import{S as E}from"./EzFormMui-Dl2q2DE_.js";const H=["* Cancellation/Changes: JMC Transportation has 48 hours prior to time of service Cancellation policy.","Cancellation with less than fourteen (14) days notice will be charged the full amount of the chartered service.","Service requested must be cancelled by the booking party with a minimum of 14 days notice in order to receive a full refund.","Cancellation with less than 14 days notice is not refundable."];function h({item:s}){const t=g(),{name:o,picPath:m,text:f,formFields:u}=s,[i,x]=c.useState({expanded:!1,containerHeight:null}),d=c.useRef();return c.useEffect(()=>{const a=d.current;a&&x(n=>({...n,containerHeight:a.offsetHeight}))},[]),e.jsxs(r,{r:1,justifyContent:"flex-start",sx:{position:"relative",height:{xs:i.expanded?`calc(36rem + ${i.containerHeight-180}px)`:"calc(32rem + 4px)",sm:i.expanded?`calc(36rem + ${i.containerHeight-180}px)`:"34rem",md:i.expanded?`calc(36rem + ${i.containerHeight-180}px)`:"36rem"},overflow:"hidden",border:{xs:`1px solid ${t.palette.grey[700]}`,lg:`1px solid ${t.palette.grey[800]}`},transition:"all 200ms","&:hover":{boxShadow:t.shadows[4]}},children:[e.jsx(r,{p:"0 0 0 1rem",justifyContent:"center",sx:{height:"4rem",minHeight:"4rem",width:"100%",backgroundColor:"rgba(0,0,0,0.32)",position:"absolute",backdropFilter:"blur(5px)"},children:Array.isArray(o)?o.map((a,n)=>e.jsx(l,{text:a,sx:{...n===0&&{fontSize:"1.5rem"},...n===1&&{fontSize:"1rem"}}},n)):e.jsx(l,{variant:"h4",text:o,sx:{color:"white"}})}),e.jsx(r,{sx:{minHeight:"16rem",maxHeight:"16rem"},children:e.jsx(j,{path:m,fit:"fill"})}),e.jsx(r,{p:2,sx:{overflow:"hidden"},children:e.jsx(r,{ref:d,children:f.map((a,n)=>e.jsx(l,{text:a,sx:{color:t.palette.jg.lightColor}},n))})}),i.containerHeight>192&&e.jsx(r,{alignItems:"flex-end",p:2,children:e.jsx(l,{text:"Read more",color:t.palette.warning.dark,onClick:()=>x(a=>({...a,expanded:!i.expanded})),sx:{borderBottom:"1px solid transparent",cursor:"pointer",transition:"all 200ms",height:"80px",maxHeight:"80px"}})}),e.jsxs(r,{justifyContent:"flex-end",p:2,direction:"row",gap:1,sx:{position:"absolute",bottom:0,right:0},children:[e.jsx(p,{onClick:()=>window.navigate(`/services/${s.path}`,{state:s}),sx:{color:t.palette.jg.lightColor,backgroundColor:t.palette.jg.detailsBtn},children:"Details"}),e.jsx(p,{onClick:()=>window.setChildren(e.jsx(k,{name:Array.isArray(o)?o[0]:o,fields:u})),sx:{...C(t)},children:"Book Now"})]})]})}h.propTypes={item:w.object.isRequired};function B(){return e.jsx(r,{p:2,r:2,children:H.map((s,t)=>e.jsx(l,{text:s,color:"#999"},t))})}function R(){return e.jsxs(e.Fragment,{children:[e.jsx(y,{}),e.jsxs(v,{mask:!0,children:[e.jsx(r,{p:"clamp(3rem, 3vw + 1rem, 3rem) clamp(3rem, 3vw + 1rem, 3rem)",sx:{position:"relative"},children:e.jsx(b,{text:"SERVICES",variant:"h2"})}),e.jsx(S,{sx:{padding:"16px",height:"100%",width:"100%",display:"grid",gridGap:"16px",gridTemplateColumns:{lg:"repeat(4, 1fr)",md:"repeat(3, 1fr)",sm:"repeat(2, 1fr)",xs:"repeat(1, 1fr)"}},children:E.map((s,t)=>e.jsx(h,{item:s,id:t},t))}),e.jsx(r,{p:2,children:e.jsx(B,{})})]})]})}export{R as default};