@@ -6,6 +6,7 @@ import BaseLayout from "../layouts/BaseLayout.astro";
66import GradientButton from " ../components/GradientButton.astro" ;
77import OutlinedButton from " ../components/OutlinedButton.astro" ;
88import RocketAnimated from " ../components/RocketAnimated.astro" ;
9+ import InstagramWidget from " ../components/InstagramWidget.astro" ;
910
1011import { Content as MeetMike } from " ../meet_astro_mike.md" ;
1112
@@ -52,7 +53,7 @@ import teamworkHighlightedSpeakingImg from "../assets/highlighted_speaking/teamw
5253 <GradientButton link =" /speaking" text =" SPEAKING INFORMATION" />
5354 </div >
5455
55- <div class =" z-10 col-span-4 col-start-4 sm:col-start-5 row-span-1 row-start-4 lg:absolute lg:left-20 lg:col-start-1 lg:row-start-2 lg:mb-40 2xl:ml-40" >
56+ <div class =" z-10 col-span-4 col-start-4 row-span-1 row-start-4 sm:col-start-5 lg:absolute lg:left-20 lg:col-start-1 lg:row-start-2 lg:mb-40 2xl:ml-40" >
5657 <h3 class =" flex flex-wrap font-jost text-[36px] leading-[2.8rem] text-white sm:text-[32px] md:text-[48px] lg:text-6xl" >Mike Massimino</h3 >
5758 </div >
5859
@@ -79,6 +80,8 @@ import teamworkHighlightedSpeakingImg from "../assets/highlighted_speaking/teamw
7980 <MeetMike />
8081 </div >
8182
83+ <div id =" insta-trigger" class =" h-1" ></div >
84+
8285 <div class =" col-span-4 col-start-1 row-span-2 row-start-7 md:col-span-5 md:col-start-8 md:row-start-2 md:h-auto md:max-w-md lg:row-start-1" >
8386 <Picture src ={ meetMikeImage } alt =" Mike Massimino speaking on stage." loading =" eager" />
8487 </div >
@@ -107,8 +110,8 @@ import teamworkHighlightedSpeakingImg from "../assets/highlighted_speaking/teamw
107110 </div >
108111
109112 <!-- Content Cards -->
110- <section class =" bg-gradient-to-r from-[#7DCFFF] via-[#2E8FE7] to-[#091E3A] px-3 py-8 lg:pt-40" >
111- <div class =" mx-auto flex max-w-96 flex-col space-y-8 lg:max-w-none lg:flex-row lg:items-center lg:justify-center lg:space-y-0" >
113+ <section class =" bg-gradient-to-r from-[#7DCFFF] via-[#2E8FE7] to-[#091E3A] py-8 lg:pt-40" >
114+ <div class =" mx-auto flex max-w-96 flex-col space-y-8 px-5 lg:max-w-none lg:flex-row lg:items-center lg:justify-center lg:space-y-0" >
112115 <!-- Card 1 -->
113116 <div class =" lg:order-2 lg:ml-8" >
114117 <div class =" lg:flex lg:flex-col lg:items-center" >
@@ -144,7 +147,7 @@ import teamworkHighlightedSpeakingImg from "../assets/highlighted_speaking/teamw
144147 <Image
145148 src ={ tvMoviesImg }
146149 loading =" lazy"
147- class =" flex aspect-[4/3] lg:h-60 h- full rounded-l-3xl object-cover shadow-lg lg:max-w-[20em]"
150+ class =" flex aspect-[4/3] h- full rounded-l-3xl object-cover shadow-lg lg:h-60 lg:max-w-[20em]"
148151 alt =" Mike's cameo on the Big Bang Theory."
149152 />
150153 </div >
@@ -170,7 +173,7 @@ import teamworkHighlightedSpeakingImg from "../assets/highlighted_speaking/teamw
170173 <Image
171174 src ={ frequentGuestImg }
172175 loading =" lazy"
173- class =" flex lg:h-60 h- full object-cover rounded-l-3xl shadow-lg lg:max-w-[20em]"
176+ class =" flex h- full rounded-l-3xl object-cover shadow-lg lg:h-60 lg:max-w-[20em]"
174177 alt =" Mike on the television."
175178 />
176179 </div >
@@ -194,6 +197,17 @@ import teamworkHighlightedSpeakingImg from "../assets/highlighted_speaking/teamw
194197 </div >
195198 </section >
196199
200+ <!-- Floating Instagram Widget (Desktop)
201+ <div class="relative hidden lg:mx-auto lg:max-w-7xl 2xl:block">
202+ <div class="absolute left-4 w-72">
203+ <div class="border-gray-200 sticky z-20 overflow-hidden rounded-2xl border bg-white shadow-xl">
204+ <div class="max-h-[calc(100vh-120px)] overflow-y-auto p-1">
205+ <InstagramWidget username="astromikemassimino" postCount={3} />
206+ </div>
207+ </div>
208+ </div>
209+ </div> -->
210+
197211 <!-- Inspiring Talks Section -->
198212 <section class =" bg-gradient-to-r from-[#EDF5FF] to-[#D7E6FF]" >
199213 <div class =" space-y-5 px-6 pb-14 pt-5 lg:mx-auto lg:max-w-5xl lg:gap-12 lg:px-16 xl:max-w-6xl xl:pt-8" >
@@ -264,9 +278,43 @@ import teamworkHighlightedSpeakingImg from "../assets/highlighted_speaking/teamw
264278 </div >
265279 </div >
266280 </section >
281+
282+ <div class =" lg:mx-auto lg:max-w-7xl" >
283+ <!-- Mobile Instagram Widget (inline) -->
284+ <div class =" mt-16 px-5 2xl:hidden" >
285+ <InstagramWidget />
286+ </div >
287+ </div >
288+
289+ <div id =" floating-insta" class =" pointer-events-none fixed bottom-4 left-4 z-50 hidden opacity-0 transition-opacity duration-500 2xl:block -translate-y-[240px]" >
290+ <div class =" border-gray-200 rounded-2xl border bg-white shadow-xl" >
291+ <InstagramWidget username =" astromikemassimino" postCount ={ 3 } />
292+ </div >
293+ </div >
267294</BaseLayout >
268295
269296<script >
270297 // @ts-ignore
271298 import fsLightbox from "fslightbox";
299+ const trigger = document.getElementById("insta-trigger");
300+ const widget = document.getElementById("floating-insta");
301+
302+ const observer = new IntersectionObserver(
303+ (entries) => {
304+ entries.forEach((entry) => {
305+ if (!entry.isIntersecting && entry.boundingClientRect.top < 0) {
306+ // User has scrolled PAST the trigger point
307+ widget.classList.remove("opacity-0", "pointer-events-none");
308+ widget.classList.add("opacity-100");
309+ } else {
310+ // User is above the trigger point
311+ widget.classList.add("opacity-0", "pointer-events-none");
312+ widget.classList.remove("opacity-100");
313+ }
314+ });
315+ },
316+ { threshold: 0 },
317+ );
318+
319+ observer.observe(trigger);
272320</script >
0 commit comments