1import{j as e,m as d}from"./motion-DjGABStX.js";import{u as f}from"./query-DbGnfXKt.js";import{u as h,B as j,s as b}from"./index-BJvU1pXf.js";import{f as y}from"./FocalPointPicker-CWMDUFV2.js";import{g as _,s as w}from"./pressContent-Dyx6JBjn.js";import{r as N,aA as v}from"./icons-DVToBswu.js";import{L as m}from"./react-vendor-BHrJ9XZd.js";import"./supabase-92svyh75.js";import"./dialog-Bsqd6gcU.js";const S=()=>{const{t,i18n:g}=h(),p=g.language,{data:i=[]}=f({queryKey:["latest-press-home"],queryFn:async()=>{const{data:s}=await b.from("press_releases").select("id, title_tr, title_en, excerpt_tr, excerpt_en, client_name, brand_names, slug_tr, slug_en, original_language, published_date, image_urls, image_focal_points").eq("is_published",!0).order("published_date",{ascending:!1}).limit(8);return s||[]}});return i.length===0?null:e.jsx("section",{className:"py-20 md:py-28 lg:py-36 bg-gradient-to-br from-background via-background to-orange/5",children:e.jsxs("div",{className:"container-asymmetric",children:[e.jsxs(d.div,{initial:{opacity:0,y:24},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{duration:.6},className:"flex flex-col md:flex-row md:items-end justify-between gap-6 mb-12",children:[e.jsxs("div",{className:"max-w-2xl",children:[e.jsx("h2",{className:"text-3xl md:text-4xl lg:text-5xl font-display font-bold kerning-tight mb-4",children:t("press.latestTitle")}),e.jsx("p",{className:"text-muted-foreground leading-generous",children:t("press.latestSubtitle")})]}),e.jsx(j,{asChild:!0,variant:"outline",className:"self-start md:self-end gap-2",children:e.jsxs(m,{to:"/press",children:[t("press.viewAll")," ",e.jsx(N,{className:"w-4 h-4"})]})})]}),e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-6 md:gap-8",children:i.map((s,x)=>{var r,o;const a=_(s),n=w(a.title)||a.title,u=a.slug,l=(r=s.image_urls)==null?void 0:r[0];return e.jsx(d.article,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{duration:.5,delay:x*.1},className:"group bg-card border border-border rounded-lg overflow-hidden flex flex-col hover:shadow-lg transition-shadow",children:e.jsxs(m,{to:`/press/${u}`,className:"flex flex-col h-full",children:[l&&e.jsx("div",{className:"aspect-[4/3] bg-muted overflow-hidden sm:aspect-[3/2] lg:aspect-[16/10]",children:e.jsx("img",{src:l,alt:`${s.client_name?`${s.client_name} â `:""}${n}`,loading:"lazy",decoding:"async",className:"w-full h-full object-cover group-hover:scale-[1.03] transition-transform duration-500",style:{objectPosition:y(s.image_focal_points,l)}})}),e.jsxs("div",{className:"p-6 flex-1 flex flex-col",children:[e.jsxs("div",{className:"flex items-center gap-2 text-xs text-muted-foreground mb-3",children:[e.jsx(v,{className:"w-3 h-3"}),e.jsx("span",{children:new Date(s.published_date).toLocaleDateString(p==="tr"?"tr-TR":"en-US",{year:"numeric",month:"long",day:"numeric"})}),s.client_name&&e.jsxs(e.Fragment,{children:[e.jsx("span",{children:"·"}),e.jsx("span",{className:"font-medium text-foreground",children:s.client_name})]})]}),(((o=s.brand_names)==null?void 0:o.length)??0)>0&&e.jsx("div",{className:"flex flex-wrap gap-1 mb-2",children:s.brand_names.map(c=>e.jsx("span",{className:"text-[10px] uppercase tracking-wider px-2 py-0.5 rounded-full bg-accent/10 text-accent",children:c},c))}),e.jsx("h3",{className:"font-display text-xl font-semibold mb-2 group-hover:text-accent transition-colors",children:n})]})]})},s.id)})})]})})};export{S as default};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.