PageSourceSearch

https://strite.ai/assets/HomePage-BJ97AayD.js

js strite.ai collected 2026-10-05 13:36:44 UTC 26,997 bytes, 1 lines download raw bytes

1import{r as C,e}from"./vendor-react-BsIZDGja.js";import{a as xe}from"./vendor-clerk-BIGLA9lg.js";import{d as Se,a as be,b as je,u as te,g as we,h as Me}from"./index-BOKch6Y6.js";import{c as ue}from"./createLucideIcon-BvKhkVn4.js";import{T as re,F as ve}from"./trending-up-TLJyk8yN.js";import{Z as De}from"./zap-CeoDlq7A.js";import{D as ke}from"./disc-C5wY3eDW.js";import{C as ae}from"./chevron-down-BepMgxNz.js";import{R as le,A as Be,C as Fe,X as Te,Y as Ce,T as ce,a as Ie,P as ze,b as $e,d as Ae,L as Re}from"./vendor-recharts-C4n2D9md.js";import{t as M,c as Le,g as de,e as Je,m as pe,a as X,b as Oe,f as Z}from"./format-DhIxCKRC.js";import{P as Ee}from"./plus-BKuYJtMO.js";import"./vendor-query-CoZHtb0k.js";import"./vendor-gsap-a3sj5zmn.js";const Ne=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],_e=ue("arrow-right",Ne);const Ge=[["path",{d:"M5 21v-6",key:"1hz6c0"}],["path",{d:"M12 21V3",key:"1lcnhd"}],["path",{d:"M19 21V9",key:"unv183"}]],ee=ue("chart-no-axes-column",Ge);function K(i,o){const s=M(i),f=M(o),a=s.getTime()-f.getTime();return a<0?-1:a>0?1:a}function We(i){return Le(i,Date.now())}function He(i,o){const s=M(i),f=M(o),a=s.getFullYear()-f.getFullYear(),j=s.getMonth()-f.getMonth();return a*12+j}function Ue(i){return o=>{const f=(i?Math[i]:Math.trunc)(o);return f===0?0:f}}function Ye(i,o){return+M(i)-+M(o)}function Pe(i){const o=M(i);return o.setHours(23,59,59,999),o}function Xe(i){const o=M(i),s=o.getMonth();return o.setFullYear(o.getFullYear(),s+1,0),o.setHours(23,59,59,999),o}function Ke(i){const o=M(i);return+Pe(o)==+Xe(o)}function qe(i,o){const s=M(i),f=M(o),a=K(s,f),j=Math.abs(He(s,f));let v;if(j<1)v=0;else{s.getMonth()===1&&s.getDate()>27&&s.setDate(30),s.setMonth(s.getMonth()-a*j);let d=K(s,f)===-a;Ke(M(i))&&j===1&&K(i,f)===1&&(d=!1),v=a*(j-Number(d))}return v===0?0:v}function Ve(i,o,s){const f=Ye(i,o)/1e3;return Ue(s?.roundingMethod)(f)}function Qe(i,o,s){const f=Oe(),a=s?.locale??f.locale??Je,j=2520,v=K(i,o);if(isNaN(v))throw new RangeError("Invalid time value");const d=Object.assign({},s,{addSuffix:s?.addSuffix,comparison:v});let I,z;v>0?(I=M(o),z=M(i)):(I=M(i),z=M(o));const l=Ve(z,I),q=(de(z)-de(I))/1e3,r=Math.round((l-q)/60);let u;if(r<2)return s?.includeSeconds?l<5?a.formatDistance("lessThanXSeconds",5,d):l<10?a.formatDistance("lessThanXSeconds",10,d):l<20?a.formatDistance("lessThanXSeconds",20,d):l<40?a.formatDistance("halfAMinute",0,d):l<60?a.formatDistance("lessThanXMinutes",1,d):a.formatDistance("xMinutes",1,d):r===0?a.formatDistance("lessThanXMinutes",1,d):a.formatDistance("xMinutes",r,d);if(r<45)return a.formatDistance("xMinutes",r,d);if(r<90)return a.formatDistance("aboutXHours",1,d);if(r<pe){const B=Math.round(r/60);return a.formatDistance("aboutXHours",B,d)}else{if(r<j)return a.formatDistance("xDays",1,d);if(r<X){const B=Math.round(r/pe);return a.formatDistance("xDays",B,d)}else if(r<X*2)return u=Math.round(r/X),a.formatDistance("aboutXMonths",u,d)}if(u=qe(z,I),u<12){const B=Math.round(r/X);return a.formatDistance("xMonths",B,d)}else{const B=u%12,x=Math.trunc(u/12);return B<3?a.formatDistance("aboutXYears",x,d):B<9?a.formatDistance("overXYears",x,d):a.formatDistance("almostXYears",x+1,d)}}function Ze(i,o){return Qe(i,We(i),o)}const p="#FF5C1A",fe="#FF2D00",_=["#FF5C1A","#FF2D00","#CC3D0A","#FF7A45","#8B2010","#E04A15","#FF9060"],ge={brand_experience:"Brand Experience",marketing:"Marketing",pr:"PR",audio_ads:"Audio Ads",tvc:"TVC",design:"Design",radio:"Radio"};function et({active:i,payload:o,label:s}){const{isDark:f}=te(),a=d=>f?`rgba(255,255,255,${d})`:`rgba(26,5,0,${d})`,j=f?"#ffffff":"#1A0500",v=f?"rgba(13,2,0,0.96)":"rgba(247,244,242,0.98)";return!i||!o?.length?null:e.jsxs("div",{style:{background:v,border:"1px solid rgba(255,92,26,0.35)",borderRadius:8,padding:"8px 14px",fontFamily:"JetBrains Mono, monospace"},children:[e.jsx("p",{style:{fontSize:9,color:a(.4),letterSpacing:"0.22em",textTransform:"uppercase",marginBottom:3},children:s}),e.jsxs("p",{style:{fontSize:14,color:p},children:[e.jsx("span",{style:{color:j},children:o[0].value})," strategies"]})]})}function tt({active:i,payload:o}){const{isDark:s}=te(),f=v=>s?`rgba(255,255,255,${v})`:`rgba(26,5,0,${v}
1)`,a=s?"#ffffff":"#1A0500",j=s?"rgba(13,2,0,0.96)":"rgba(247,244,242,0.98)";return!i||!o?.length?null:e.jsxs("div",{style:{background:j,border:"1px solid rgba(255,92,26,0.35)",borderRadius:8,padding:"8px 14px",fontFamily:"JetBrains Mono, monospace"},children:[e.jsx("p",{style:{fontSize:11,color:f(.55),letterSpacing:"0.12em",marginBottom:2},children:o[0].name}),e.jsx("p",{style:{fontSize:14,color:p},children:e.jsx("span",{style:{color:a},children:o[0].value})})]})}function yt(){const{user:i}=xe(),[,o]=Se(),s=i?.id,[f,a]=C.useState(!1),[j,v]=C.useState(!1),[d,I]=C.useState(null),z=C.useRef(null),[l,q]=C.useState(()=>typeof window<"u"&&window.innerWidth<640);C.useEffect(()=>{const t=()=>q(window.innerWidth<640);return window.addEventListener("resize",t),()=>window.removeEventListener("resize",t)},[]);const{data:r}=be({userId:s||""},{query:{enabled:!!s,queryKey:we({userId:s||""})}}),{data:u,isLoading:B}=je({userId:s||""},{query:{enabled:!!s,queryKey:Me({userId:s||""})}}),x=C.useMemo(()=>{if(!u||u.length===0)return null;const t=new Date,n=Array.from({length:14},(g,h)=>{const y=new Date(t);return y.setDate(y.getDate()-(13-h)),{date:y.toISOString().slice(0,10),label:Z(y,"d MMM"),count:0}});u.forEach(g=>{const h=new Date(g.createdAt).toISOString().slice(0,10),y=n.find(b=>b.date===h);y&&y.count++});const m={};u.forEach(g=>{const h=g.discipline??"brand_experience";m[h]=(m[h]??0)+1});const S=Object.entries(m).map(([g,h])=>({key:g,name:ge[g]??g,count:h})).sort((g,h)=>h.count-g.count),w=u.filter(g=>g.generationStatus==="pending").length,D=u.length-w;return{timeData:n,disciplineData:S,generating:w,complete:D,total:u.length}},[u]),L=C.useMemo(()=>{const t=new Date;t.setHours(0,0,0,0);const n={};(u??[]).forEach(F=>{const k=new Date(F.createdAt);k.setHours(0,0,0,0);const T=k.toISOString().slice(0,10);n[T]=(n[T]??0)+1});let m=0;const S=new Date(t);for(;n[S.toISOString().slice(0,10)];)m++,S.setDate(S.getDate()-1);const w=Object.keys(n).sort();let D=w.length>0?1:0;if(w.length>1){let F=1;for(let k=1;k<w.length;k++)Math.round((new Date(w[k]).getTime()-new Date(w[k-1]).getTime())/864e5)===1?(F++,D=Math.max(D,F)):F=1}const g=new Date(t);g.setDate(g.getDate()-111),g.setDate(g.getDate()-g.getDay());const h=Math.ceil((t.getTime()-g.getTime())/864e5)+1,y=Math.ceil(h/7),b=[],N=[];let P=-1;for(let F=0;F<y;F++){const k=[];for(let T=0;T<7;T++){const R=new Date(g);R.setDate(R.getDate()+F*7+T);const ie=R.toISOString().slice(0,10);T===0&&R.getMonth()!==P&&(N.push({weekIdx:F,label:Z(R,"MMM")}),P=R.getMonth()),k.push({dateStr:ie,count:n[ie]??0,isFuture:R>t})}b.push(k)}return{currentStreak:m,longestStreak:D,weeks:b,monthLabels:N,todayStr:t.toISOString().slice(0,10)}},[u]),{isDark:G}
1=te(),me=G?"#0D0200":"#ffffff",W=G?"#ffffff":"#1A0500",c=t=>G?`rgba(255,255,255,${t})`:`rgba(26,5,0,${t})`,$={background:G?"rgba(255,255,255,0.04)":"#f7f4f2",border:`1px solid ${G?"rgba(255,255,255,0.08)":"rgba(26,5,0,0.10)"}`,borderRadius:14,padding:"24px 28px",backdropFilter:"blur(20px)",minWidth:0},Y={fontFamily:"JetBrains Mono, monospace",fontSize:11,letterSpacing:"0.28em",textTransform:"uppercase",color:c(.25),marginBottom:16,display:"flex",alignItems:"center",gap:8};if(!s)return null;new Date().getHours();const V=i?.firstName??"",ne=V?V.charAt(0).toUpperCase()+V.slice(1):"",Q=C.useMemo(()=>{const t=new Date().getHours(),n=t<12?"Good morning":t<17?"Good afternoon":"Good evening",m=[{before:n},{before:n},{before:"Hey"},{before:"Welcome back"},{before:"Back at it"},{before:"Great to see you"},{before:"Ready to build",suffix:"?"},{before:"The studio is open"},{before:"Make it count"},{before:"Let's get to work"},{before:"What's the brief today",suffix:"?"}];return m[Math.floor(Math.random()*m.length)]},[]),H=r&&r.creditAllowance>0?Math.min(100,r.creditsUsedThisCycle/r.creditAllowance*100):0,he=r?.plan?r.plan.charAt(0).toUpperCase()+r.plan.slice(1):"Free",ye=!1,A=r?.creditsUsedThisCycle??0,J=r?Math.max(0,r.creditAllowance-A):null,oe=r?.creditAllowance??0,O=x?.total??0,U=x?.disciplineData?.[0],E=x?.timeData?.slice(-7).reduce((t,n)=>t+n.count,0)??0,se=C.useMemo(()=>{const t=[];if(O===0)t.push("No strategies yet. The best brief of your career is one click away.","A blank slate. The most exciting place to start.","Your creative output starts here. Drop a brief.","Nothing yet. Let's build something worth talking about.");else{if(t.push(`You've built ${O} ${O===1?"strategy":"strategies"} in total. Not bad.`,`${O} ${O===1?"strategy":"strategies"} generated. Your studio is alive.`),A>0&&t.push(`${A} ${A===1?"strategy":"strategies"} created this month. The engine is running.`,`You've been active. ${A} ${A===1?"brief":"briefs"} turned into strategy this month.`),E>0?t.push(`${E} ${E===1?"strategy":"strategies"} in the last 7 days. Keep the streak alive.`,`Active week. ${E} ${E===1?"project":"projects"} built in the past 7 days.`):t.push("It's been quiet lately. Ready to pick things back up?"),U){const n=U.name;t.push(`Your most-used discipline is ${n}. ${U.count} ${U.count===1?"project":"projects"} so far.`,`You spend most of your time in ${n}. Specialisation suits you.`)}J!==null&&(J===0?t.push("Monthly limit reached. Upgrade to keep creating this month.",`You've maxed out this month's ${oe} strategies. Upgrade to unlock more.`):t.push(`${J} ${J===1?"strategy":"strategies"} left this month. Make them count.`,`${A} of ${oe} monthly strategies used. ${J} still available.`))}return t[Math.floor(Math.random()*t.length)]},[O,A,E,U?.key,J,ye]);return e.jsx("div",{style:{flex:1,display:"flex",flexDirection:"column",minHeight:0,background:me,color:W},children:e.jsx("div",{style:{flex:1,position:"relative",minHeight:0},children:e.jsxs("div",{style:{position:"absolute",inset:0,overflowY:"auto",overflowX:"hidden"},children:[e.jsxs("div",{style:{padding:l?"24px 20px 20px":"40px 48px 32px",borderBottom:`1px solid ${c(.04)}`},children:[e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:11,letterSpacing:"0.28em",textTransform:"uppercase",color:c(.25),marginBottom:10},children:"Studio"}),e.jsxs("p",{style:{fontFamily:"'JetBrains Mono', monospace",fontSize:"clamp(20px,2vw,28px)",color:c(.55),letterSpacing:"0.01em",lineHeight:1.5,margin:0},children:[Q.before,ne?e.jsxs(e.Fragment,{children:[", ",e.jsx("span",{style:{color:p},children:ne})]}):"",Q.suffix??"",Q.suffix?"":".",se?e.jsxs(e.Fragment,{children:[" ",se]}):""]})]}),e.jsxs("div",{style:{padding:l?"20px 16px 40px":"36px 48px 56px",display:"flex",flexDirection:"column",gap:l?16:28},children:[e.jsx("div",{style:{display:"grid",gridTemplateColumns:l?"repeat(2, 1fr)":"repeat(auto-fit, minmax(160px, 1fr))",gap:l?10:14},children:[{label:"Total Strategies",value:B?"—":x?.total??0,sub:"all time",icon:e.jsx(ee,{style:{width:15,height:15,color:p}})}
1,{label:"Credits Used",value:B?"—":(r?.creditsUsedThisCycle??0).toLocaleString(),sub:`of ${(r?.creditAllowance??0).toLocaleString()}`,icon:e.jsx(re,{style:{width:15,height:15,color:p}})},{label:"In Progress",value:B?"—":x?.generating??0,sub:"generating now",icon:e.jsx(De,{style:{width:15,height:15,color:p}})},{label:"Plan",value:he,sub:r?.billingPeriod??"free tier",icon:e.jsx(ee,{style:{width:15,height:15,color:p}})}].map(({label:t,value:n,sub:m,icon:S})=>e.jsxs("div",{style:{...$,padding:"20px 22px"},children:[e.jsxs("div",{style:{display:"flex",alignItems:"center",gap:8,marginBottom:12},children:[S,e.jsx("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:11,letterSpacing:"0.22em",textTransform:"uppercase",color:c(.3)},children:t})]}),e.jsx("p",{style:{fontFamily:"'JetBrains Mono', monospace",textTransform:"uppercase",fontSize:"clamp(22px,2.8vw,36px)",color:W,lineHeight:1,marginBottom:6},children:n}),e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:12,letterSpacing:"0.12em",color:c(.22),textTransform:"uppercase"},children:m})]},t))}),r&&e.jsxs("div",{style:{...$},children:[e.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",marginBottom:14},children:[e.jsx("p",{style:Y,children:"Studio Credits"}),e.jsxs("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:13,color:c(.35),letterSpacing:"0.08em"},children:[r.creditsUsedThisCycle.toLocaleString()," / ",r.creditAllowance.toLocaleString()]})]}),e.jsx("div",{style:{height:6,borderRadius:4,background:c(.07),overflow:"hidden"},children:e.jsx("div",{style:{height:"100%",borderRadius:4,width:`${H}%`,background:H>90?`linear-gradient(90deg, ${p}, ${fe})`:`linear-gradient(90deg, ${p}cc, ${p})`,transition:"width 0.6s ease"}})}),H>80&&e.jsxs("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:12,letterSpacing:"0.14em",color:`${fe}cc`,textTransform:"uppercase",marginTop:10},children:[H>=100?"Cycle limit reached · ":`${Math.round(H)}% used · `,e.jsx("span",{onClick:()=>o("/pricing"),style:{color:p,textDecoration:"underline",cursor:"none"},children:"Upgrade"})]})]}),r&&e.jsxs("div",{style:{...$},children:[e.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",marginBottom:12},children:[e.jsxs("p",{style:{...Y,display:"flex",alignItems:"center",gap:7},children:[e.jsx(ke,{style:{width:11,height:11}}),"Credit Balance"]}),e.jsx("span",{style:{fontFamily:"'JetBrains Mono', monospace",fontSize:26,color:p,letterSpacing:"0.02em",lineHeight:1},children:(r.creditBalance??0).toLocaleString()})]}),e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:12,color:c(.28),letterSpacing:"0.06em",lineHeight:1.65,marginBottom:16},children:"One-time top-ups that extend your monthly allowance. They never expire and carry over indefinitely."}),r.plan==="free"?e.jsx("button",{onClick:()=>o("/pricing"),style:{display:"inline-flex",alignItems:"center",gap:6,fontFamily:"JetBrains Mono, monospace",fontSize:11,textTransform:"uppercase",letterSpacing:"0.16em",color:p,background:"none",border:"none",cursor:"none",padding:0,transition:"opacity 0.15s"},onMouseEnter:t=>{t.currentTarget.style.opacity="0.65"},onMouseLeave:t=>{t.currentTarget.style.opacity="1"},children:"Upgrade to buy credits →"}):e.jsx("button",{onClick:()=>o("/tokens"),style:{display:"inline-flex",alignItems:"center",gap:6,fontFamily:"JetBrains Mono, monospace",fontSize:11,textTransform:"uppercase",letterSpacing:"0.16em",color:p,background:"none",border:"none",cursor:"none",padding:0,transition:"opacity 0.15s"},onMouseEnter:t=>{t.currentTarget.style.opacity="0.65"},onMouseLeave:t=>{t.currentTarget.style.opacity="1"},children:"Buy more credits →"})]}),e.jsxs("div",{style:$,children:[e.jsxs("button",{onClick:()=>a(t=>!t),style:{display:"flex",alignItems:"center",justifyContent:"space-between",width:"100%",background:"none",border:"none",cursor:"none",marginBottom:f?0:20,padding:0},children:[e.jsxs("p",{style:Y,children:[e.jsx(re,{style:{width:12,height:12}}),"14-Day Activity"]}),e.jsx(ae,{style:{width:14,height:14,color:c(.25),transform:f?"rotate(-90deg)":"rotate(0deg)",transition:"transform 0.2s",flexShrink:0}})]}),!f&&(x?e.jsx(le,{width:"100%",height:200,children:e.jsxs(Be,{data:x.timeData,margin:{top:4,right:4,left:-28,bottom:0},children:[e.jsx("defs",{children:e.jsxs("linearGradient",{id:"activityGrad",x1:"0",y1:"0",x2:"0",y2:"1",children:[e.jsx("stop",{offset:"5%",
1stopColor:p,stopOpacity:.28}),e.jsx("stop",{offset:"95%",stopColor:p,stopOpacity:0})]})}),e.jsx(Fe,{strokeDasharray:"3 3",stroke:c(.05)}),e.jsx(Te,{dataKey:"label",tick:{fontFamily:"JetBrains Mono, monospace",fontSize:11,fill:c(.25),letterSpacing:"0.08em"},axisLine:!1,tickLine:!1,interval:1}),e.jsx(Ce,{allowDecimals:!1,tick:{fontFamily:"JetBrains Mono, monospace",fontSize:11,fill:c(.25)},axisLine:!1,tickLine:!1}),e.jsx(ce,{content:e.jsx(et,{})}),e.jsx(Ie,{type:"monotone",dataKey:"count",stroke:p,strokeWidth:2,fill:"url(#activityGrad)",dot:!1,activeDot:{r:4,fill:p,stroke:"#0D0200",strokeWidth:2}})]})}):e.jsx("div",{style:{height:200,display:"flex",alignItems:"center",justifyContent:"center"},children:e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:11,letterSpacing:"0.2em",textTransform:"uppercase",color:c(.18)},children:"No activity yet — create your first strategy"})}))]}),e.jsxs("div",{style:{display:"grid",gridTemplateColumns:l?"1fr":"1fr 1fr",gap:16,alignItems:"stretch",minWidth:0},children:[e.jsxs("div",{style:{...$,padding:l?"20px 16px":"24px 28px",overflow:"hidden"},children:[e.jsxs("button",{onClick:()=>v(t=>!t),style:{display:"flex",alignItems:"center",justifyContent:"space-between",width:"100%",background:"none",border:"none",cursor:"none",marginBottom:j?0:20,padding:0},children:[e.jsxs("p",{style:Y,children:[e.jsx(ee,{style:{width:12,height:12}}),"Discipline Breakdown"]}),e.jsx(ae,{style:{width:14,height:14,color:"rgba(255,255,255,0.25)",transform:j?"rotate(-90deg)":"rotate(0deg)",transition:"transform 0.2s",flexShrink:0}})]}),!j&&(x&&x.disciplineData.length>0?e.jsxs("div",{style:{display:"flex",flexDirection:"column",gap:20},children:[e.jsx(le,{width:"100%",height:l?200:220,children:e.jsxs(ze,{margin:{top:l?12:5,right:5,bottom:5,left:5},children:[e.jsx($e,{data:x.disciplineData,dataKey:"count",nameKey:"name",cx:"50%",cy:"50%",outerRadius:l?68:88,innerRadius:l?34:44,paddingAngle:2,stroke:"none",children:x.disciplineData.map((t,n)=>e.jsx(Ae,{fill:_[n%_.length]},n))}),e.jsx(ce,{content:e.jsx(tt,{})}),e.jsx(Re,{formatter:t=>e.jsx("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:10,letterSpacing:"0.1em",color:c(.55)},children:t}),iconSize:8})]})}),e.jsx("div",{style:{display:"flex",flexDirection:"column",gap:10},children:x.disciplineData.map(({name:t,count:n},m)=>{const S=x.total>0?n/x.total*100:0;return e.jsxs("div",{children:[e.jsxs("div",{style:{display:"flex",justifyContent:"space-between",gap:8,marginBottom:5,minWidth:0},children:[e.jsx("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:12,letterSpacing:"0.08em",color:c(.5),textTransform:"uppercase",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",minWidth:0},children:t}),e.jsxs("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:12,color:_[m%_.length],letterSpacing:"0.08em",flexShrink:0,whiteSpace:"nowrap"},children:[n," · ",Math.round(S),"%"]})]}),e.jsx("div",{style:{height:4,borderRadius:3,background:c(.06)},children:e.jsx("div",{style:{height:"100%",borderRadius:3,width:`${S}%`,background:_[m%_.length],transition:"width 0.5s ease"}})})]},t)})})]}):e.jsx("div",{style:{height:160,display:"flex",alignItems:"center",justifyContent:"center"},children:e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:11,letterSpacing:"0.2em",textTransform:"uppercase",color:c(.18)},children:"No strategies yet"})}))]}),e.jsxs("div",{style:{...$,padding:l?"20px 16px":"24px 28px",display:"flex",flexDirection:"column"},children:[e.jsxs("div",{style:{display:"flex",alignItems:"flex-start",justifyContent:"space-between",marginBottom:20,gap:8,minWidth:0},children:[e.jsx("div",{style:{minWidth:0},children:e.jsxs("div",{style:{display:"flex",alignItems:"center",gap:6,marginBottom:4,flexWrap:"nowrap"},children:[e.jsx(ve,{style:{width:14,height:14,color:p,flexShrink:0}}),e.jsx("span",{style:{fontFamily:"'JetBrains Mono', monospace",fontSize:l?20:"clamp(22px,2.2vw,32px)",color:W,letterSpacing:"-0.01em",lineHeight:1,flexShrink:0},children:L.currentStreak}),e.jsx("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:l?13:15,color:c(.45),letterSpacing:"0.04em",whiteSpace:"nowrap"},children:"day streak"})]})}),e.jsxs("div",{style:{textAlign:"right",flexShrink:0},children:[e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:l?9:11,letterSpacing:"0.14em",textTransform:"uppercase",color:c(.3),marginBottom:2,whiteSpace:"nowrap"},children:"Longest"}),e.jsxs("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:l?13:15,color:p,letterSpacing:"0.06em",whiteSpace:"nowrap"},children:[L.longestStreak," days"]})]})]}),e.jsx("div",{ref:z,style:{position:"relative",flex:1,display:"flex",flexDirection:"column",justifyContent:"space-between"},onMouseLeave:()=>I(null),children:(()=>{const t=L.weeks.length,n=l?Math.min(10,t):t,m=t-n,S=L.weeks.slice(m),w=l?14:20,D=l?3:4,g=l?22:32;return e.jsxs(e.Fragment,{children:[e.jsx("div",{style:{display:"flex",marginBottom:6,paddingLeft:g},children:S.map((h,y)=>{const b=L.monthLabels.find(N=>N.weekIdx===y+m);return e.jsx("div",{style:{width:w,flexShrink:0,marginRight:D},children:b&&e.jsx("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:9,color:c(.3),letterSpacing:"0.05em",whiteSpace:"nowrap"},children:b.label})},y)})}),e.jsxs("div",{style:{display:"flex",gap:0},children:[e.jsx("div",{style:{display:"flex",flexDirection:"column",gap:D,marginRight:l?5:8},children:["S","M","T","W","T","F","S"].map((h,y)=>e.jsx("div",{style:{height:w,display:"flex",alignItems:"center"},children:e.jsx("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:l?9:11,
1color:y%2===1?c(.28):"transparent",letterSpacing:"0.05em",lineHeight:1},children:h})},y))}),e.jsx("div",{style:{display:"flex",gap:D,flex:1},children:S.map((h,y)=>e.jsx("div",{style:{display:"flex",flexDirection:"column",gap:D,flexShrink:0},children:h.map(b=>{const N=b.isFuture?0:b.count===0?.07:b.count===1?.35:b.count===2?.65:.92,P=b.dateStr===L.todayStr;return e.jsx("div",{style:{width:w,height:w,borderRadius:l?3:4,flexShrink:0,background:b.isFuture?"transparent":`rgba(255,92,26,${N})`,outline:P?`2px solid ${p}`:"none",outlineOffset:1,cursor:"default",transition:"opacity 0.1s"},onMouseEnter:F=>{if(b.isFuture)return;const k=F.target.getBoundingClientRect(),T=z.current?.getBoundingClientRect();I({dateStr:b.dateStr,count:b.count,x:k.left-(T?.left??0)+10,y:k.top-(T?.top??0)-52})}},b.dateStr)})},y))})]}),d&&e.jsxs("div",{style:{position:"absolute",left:d.x,top:d.y,transform:"translateX(-50%)",background:"#1A0800",border:"1px solid rgba(255,92,26,0.3)",borderRadius:8,padding:"8px 12px",pointerEvents:"none",zIndex:10,whiteSpace:"nowrap"},children:[e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:10,color:c(.5),letterSpacing:"0.1em",marginBottom:4},children:Z(new Date(d.dateStr+"T12:00:00"),"MMM d, yyyy")}),e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:12,color:d.count>0?p:c(.35),letterSpacing:"0.06em"},children:d.count===0?"No activity":`${d.count} ${d.count===1?"strategy":"strategies"}`})]}),e.jsxs("div",{style:{display:"flex",alignItems:"center",gap:6,marginTop:12,paddingLeft:l?19:28},children:[e.jsx("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:10,color:c(.25),letterSpacing:"0.1em"},children:"LESS"}),[.07,.35,.65,.92].map((h,y)=>e.jsx("div",{style:{width:12,height:12,borderRadius:2,background:`rgba(255,92,26,${h})`}},y)),e.jsx("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:10,color:c(.25),letterSpacing:"0.1em"},children:"MORE"}),e.jsxs("div",{style:{marginLeft:"auto",display:"flex",alignItems:"center",gap:5},children:[e.jsx("div",{style:{width:12,height:12,borderRadius:2,background:"rgba(255,92,26,0.07)",outline:`1.5px solid ${p}`,outlineOffset:1}}),e.jsx("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:10,color:c(.25),letterSpacing:"0.1em"},children:"TODAY"})]})]})]})})()})]})]}),u&&u.length>0&&(()=>{const t=[...u].sort((n,m)=>new Date(m.createdAt).getTime()-new Date(n.createdAt).getTime()).slice(0,5);return e.jsxs("div",{style:$,children:[e.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",marginBottom:4},children:[e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:11,letterSpacing:"0.28em",textTransform:"uppercase",color:c(.25)},children:"Recent Strategies"}),u.length>5&&e.jsx("button",{onClick:()=>o("/dashboard"),style:{fontFamily:"JetBrains Mono, monospace",fontSize:11,color:p,letterSpacing:"0.08em",background:"none",border:"none",cursor:"none",textDecoration:"underline"},children:"View all"})]}),e.jsx("div",{style:{display:"flex",flexDirection:"column"},children:t.map((n,m)=>{const S=n.generationStatus==="pending",w=n.projectName||n.clientName||"Untitled",D=ge[n.discipline??"brand_experience"]??n.discipline??"";return e.jsxs("button",{onClick:()=>o(`/studio/${n.id}`),style:{display:"flex",alignItems:"center",justifyContent:"space-between",padding:"13px 0",borderTop:m>0?`1px solid ${c(.05)}`:"none",background:"none",border:"none",cursor:"none",textAlign:"left",width:"100%",transition:"opacity 0.15s"},onMouseEnter:g=>{g.currentTarget.style.opacity="0.65"},onMouseLeave:g=>{g.currentTarget.style.opacity="1"},children:[e.jsxs("div",{style:{display:"flex",alignItems:"center",gap:12,minWidth:0},children:[e.jsx("div",{style:{width:7,height:7,borderRadius:"50%",flexShrink:0,background:S?p:"rgba(255,92,26,0.35)"}}),e.jsxs("div",{style:{minWidth:0},children:[e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:16,color:S?`${p}bb`:W,letterSpacing:"0.02em",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:S?"Generating…":w}),n.clientName&&!S&&w!==n.clientName&&e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:13,color:c(.28),letterSpacing:"0.04em",marginTop:3},children:n.clientName})]})]}),e.jsxs("div",{style:{display:"flex",alignItems:"center",gap:l?8:16,flexShrink:0},children:[D&&!l&&e.jsx("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:12,color:c(.22),letterSpacing:"0.1em",textTransform:"uppercase"},children:D}),e.jsx("span",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:l?11:12,color:c(.18),letterSpacing:"0.04em",whiteSpace:"nowrap"}
1,children:Ze(new Date(n.createdAt),{addSuffix:!0})}),e.jsx(_e,{style:{width:14,height:14,color:c(.18),flexShrink:0}})]})]},n.id)})})]})})(),e.jsxs("div",{style:{...$,display:"flex",alignItems:"center",justifyContent:"space-between",flexWrap:"wrap",gap:16,padding:"28px 32px"},children:[e.jsxs("div",{children:[e.jsx("h3",{style:{fontFamily:"'JetBrains Mono', monospace",textTransform:"uppercase",color:W,fontSize:"clamp(18px,2vw,28px)",marginBottom:6},children:"Ready to create?"}),e.jsx("p",{style:{fontFamily:"JetBrains Mono, monospace",fontSize:14,color:c(.35),letterSpacing:"0.04em"},children:"Generate a new 16-card strategy deck in 90 seconds."})]}),e.jsxs("button",{onClick:()=>o("/studio"),style:{display:"flex",alignItems:"center",gap:10,padding:"12px 28px",background:"rgba(255,92,26,0.1)",border:"1px solid rgba(255,92,26,0.35)",borderRadius:10,color:p,cursor:"none",fontFamily:"'JetBrains Mono', monospace",textTransform:"uppercase",fontSize:13,letterSpacing:"0.08em",transition:"all 0.15s"},onMouseEnter:t=>{const n=t.currentTarget;n.style.background="rgba(255,92,26,0.18)",n.style.borderColor=`${p}80`},onMouseLeave:t=>{const n=t.currentTarget;n.style.background="rgba(255,92,26,0.1)",n.style.borderColor="rgba(255,92,26,0.35)"},children:[e.jsx(Ee,{style:{width:14,height:14}})," New Strategy"]})]})]})]})})})}export{yt 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.