{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "hero19",
  "title": "Cinematic Fullscreen Carousel",
  "description": "Full-screen animated carousel with multiple transition effects, next slide preview, and progress bar. Perfect for immersive storytelling and portfolio showcases.",
  "dependencies": [
    "clsx",
    "tailwind-merge",
    "lucide-react",
    "framer-motion"
  ],
  "registryDependencies": [
    "badge",
    "button"
  ],
  "files": [
    {
      "path": "registry/hero19/hero19.tsx",
      "content": "\"use client\";\n\nimport { AnimatePresence, motion, type Transition, type Variants } from \"framer-motion\";\nimport { ArrowRight, ChevronLeft, ChevronRight } from \"lucide-react\";\nimport { useCallback, useEffect, useState } from \"react\";\nimport { Badge } from \"@/components/ui/badge\";\nimport { Button } from \"@/components/ui/button\";\nimport { cn } from \"@/lib/utils\";\n\ntype TransitionType = \"fade\" | \"slide\" | \"zoom\" | \"blur\" | \"kenBurns\";\n\ninterface ButtonItem {\n  id: string;\n  label: string;\n  href?: string;\n  variant?: \"default\" | \"secondary\" | \"outline\" | \"ghost\" | \"link\" | \"destructive\";\n  icon?: React.ReactNode;\n}\n\ninterface HeroSlide {\n  id: string;\n  badge?: {\n    label: string;\n    variant?: \"default\" | \"secondary\" | \"outline\";\n  };\n  heading?: string;\n  description?: string;\n  image?: {\n    src: string;\n    alt: string;\n  };\n  buttons?: ButtonItem[];\n}\n\ninterface Hero19Props {\n  slides: HeroSlide[];\n  autoPlay?: boolean;\n  interval?: number;\n  transition?: TransitionType;\n  showDots?: boolean;\n  showArrows?: boolean;\n  showPreview?: boolean;\n  className?: string;\n}\n\nexport const hero19Demo: Hero19Props = {\n  slides: [\n    {\n      id: \"slide-1\",\n      badge: { label: \"Introducing\", variant: \"default\" },\n      heading: \"Cinematic Visual Experience\",\n      description:\n        \"Create stunning fullscreen presentations that captivate your audience. Seamless transitions, immersive backgrounds, and elegant typography.\",\n      image: {\n        src: \"https://images.unsplash.com/photo-1748726254210-67249a8ba93e?q=80&w=1974&auto=format&fit=crop\",\n        alt: \"Mountain landscape at sunset\",\n      },\n      buttons: [{ id: \"btn-1\", label: \"Get Started\", href: \"https://beste.co\" }],\n    },\n    {\n      id: \"slide-2\",\n      badge: { label: \"Design\", variant: \"default\" },\n      heading: \"Crafted for Excellence\",\n      description:\n        \"Every pixel is meticulously designed. Smooth animations and intuitive layouts create an unforgettable user experience.\",\n      image: {\n        src: \"https://images.unsplash.com/photo-1742812174813-1eebb4820037?q=80&w=1335&auto=format&fit=crop&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D\",\n        alt: \"Serene lake surrounded by mountains\",\n      },\n      buttons: [{ id: \"btn-1\", label: \"View Portfolio\", href: \"https://beste.co\" }],\n    },\n    {\n      id: \"slide-3\",\n      badge: { label: \"Innovation\", variant: \"secondary\" },\n      heading: \"Build Without Boundaries\",\n      description:\n        \"Scale your vision with powerful tools and flexible architecture. Adapt to any screen, any device, any dream.\",\n      image: {\n        src: \"https://images.unsplash.com/photo-1762952517610-8d647cabd71c?q=80&w=1299&auto=format&fit=crop\",\n        alt: \"Modern architecture at night\",\n      },\n      buttons: [{ id: \"btn-1\", label: \"Start Building\", href: \"https://beste.co\" }],\n    },\n  ],\n  autoPlay: true,\n  interval: 6000,\n  transition: \"fade\",\n  showDots: true,\n  showArrows: false,\n  showPreview: true,\n};\n\nconst getSlideVariants = (transition: TransitionType): Variants => {\n  switch (transition) {\n    case \"slide\":\n      return {\n        enter: (direction: number) => ({\n          x: direction > 0 ? \"100%\" : \"-100%\",\n          opacity: 0,\n        }),\n        center: {\n          x: 0,\n          opacity: 1,\n        },\n        exit: (direction: number) => ({\n          x: direction < 0 ? \"100%\" : \"-100%\",\n          opacity: 0,\n        }),\n      };\n    case \"zoom\":\n      return {\n        enter: {\n          scale: 1.2,\n          opacity: 0,\n        },\n        center: {\n          scale: 1,\n          opacity: 1,\n        },\n        exit: {\n          scale: 0.8,\n          opacity: 0,\n        },\n      };\n    case \"blur\":\n      return {\n        enter: {\n          filter: \"blur(20px)\",\n          opacity: 0,\n          scale: 1.1,\n        },\n        center: {\n          filter: \"blur(0px)\",\n          opacity: 1,\n          scale: 1,\n        },\n        exit: {\n          filter: \"blur(20px)\",\n          opacity: 0,\n          scale: 0.95,\n        },\n      };\n    case \"kenBurns\":\n      return {\n        enter: {\n          scale: 1.15,\n          opacity: 0,\n        },\n        center: {\n          scale: 1,\n          opacity: 1,\n        },\n        exit: {\n          scale: 1.05,\n          opacity: 0,\n        },\n      };\n    default: // fade\n      return {\n        enter: {\n          opacity: 0,\n        },\n        center: {\n          opacity: 1,\n        },\n        exit: {\n          opacity: 0,\n        },\n      };\n  }\n};\n\nconst getTransitionConfig = (transition: TransitionType): Transition => {\n  switch (transition) {\n    case \"slide\":\n      return {\n        x: { type: \"spring\", stiffness: 300, damping: 30 },\n        opacity: { duration: 0.3 },\n      };\n    case \"zoom\":\n    case \"blur\":\n      return {\n        duration: 0.8,\n        ease: [0.32, 0.72, 0, 1],\n      };\n    case \"kenBurns\":\n      return {\n        duration: 1.2,\n        ease: [0.32, 0.72, 0, 1],\n      };\n    default:\n      return {\n        duration: 0.6,\n        ease: \"easeInOut\",\n      };\n  }\n};\n\nconst textVariants: Variants = {\n  hidden: { opacity: 0, y: 30 },\n  visible: (custom: number) => ({\n    opacity: 1,\n    y: 0,\n    transition: {\n      delay: custom * 0.12,\n      duration: 0.6,\n      ease: [0.22, 1, 0.36, 1],\n    },\n  }),\n  exit: {\n    opacity: 0,\n    y: -20,\n    transition: { duration: 0.3 },\n  },\n};\n\nexport function Hero19({\n  slides,\n  autoPlay = true,\n  interval = 6000,\n  transition = \"fade\",\n  showDots = true,\n  showArrows = false,\n  showPreview = true,\n  className,\n}: Hero19Props) {\n  const [currentIndex, setCurrentIndex] = useState(0);\n  const [direction, setDirection] = useState(0);\n  const [isPaused, setIsPaused] = useState(false);\n\n  const slideCount = slides.length;\n  const currentSlide = slides[currentIndex];\n  const nextIndex = (currentIndex + 1) % slideCount;\n  const nextSlide = slides[nextIndex];\n\n  const slideVariants = getSlideVariants(transition);\n  const transitionConfig = getTransitionConfig(transition);\n\n  const paginate = useCallback(\n    (newDirection: number) => {\n      setDirection(newDirection);\n      if (newDirection === 1) {\n        setCurrentIndex((prev) => (prev + 1) % slideCount);\n      } else {\n        setCurrentIndex((prev) => (prev - 1 + slideCount) % slideCount);\n      }\n    },\n    [slideCount]\n  );\n\n  const goToSlide = useCallback(\n    (index: number) => {\n      setDirection(index > currentIndex ? 1 : -1);\n      setCurrentIndex(index);\n    },\n    [currentIndex]\n  );\n\n  useEffect(() => {\n    if (!autoPlay || slideCount <= 1 || isPaused) return;\n\n    const timer = setInterval(() => {\n      setDirection(1);\n      setCurrentIndex((prev) => (prev + 1) % slideCount);\n    }, interval);\n\n    return () => clearInterval(timer);\n  }, [autoPlay, interval, slideCount, isPaused]);\n\n  if (!currentSlide || slideCount === 0) return null;\n\n  return (\n    <section\n      className={cn(\"relative w-full min-h-[600px] h-screen overflow-hidden bg-black\", className)}\n      onMouseEnter={() => setIsPaused(true)}\n      onMouseLeave={() => setIsPaused(false)}\n    >\n      {/* Background Carousel */}\n      <AnimatePresence initial={false} custom={direction} mode=\"sync\">\n        <motion.div\n          key={currentIndex}\n          custom={direction}\n          variants={slideVariants}\n          initial=\"enter\"\n          animate=\"center\"\n          exit=\"exit\"\n          transition={transitionConfig}\n          className=\"absolute inset-0 w-full h-full\"\n        >\n          {currentSlide.image && (\n            <div className=\"w-full h-full relative\">\n              <img\n                className=\"absolute inset-0 size-full object-cover\"\n                src={currentSlide.image.src}\n                alt={currentSlide.image.alt}\n              />\n              {/* Cinematic Overlays */}\n              <div className=\"absolute inset-0 bg-gradient-to-t from-black/90 via-black/40 to-black/20\" />\n              <div className=\"absolute inset-0 bg-gradient-to-r from-black/70 via-transparent to-transparent\" />\n              <div className=\"absolute inset-0 bg-gradient-to-b from-black/30 via-transparent to-transparent\" />\n            </div>\n          )}\n        </motion.div>\n      </AnimatePresence>\n\n      {/* Content Layer */}\n      <div className=\"absolute inset-0 z-10 mx-auto px-8 md:px-16 h-full flex flex-col justify-end pb-24 lg:pb-32\">\n        <div className=\"max-w-3xl\">\n          <AnimatePresence mode=\"wait\">\n            <motion.div\n              key={`content-${currentIndex}`}\n              initial=\"hidden\"\n              animate=\"visible\"\n              exit=\"exit\"\n              className=\"flex flex-col gap-5 items-start\"\n            >\n              {/* Badge */}\n              {currentSlide.badge && (\n                <motion.div variants={textVariants} custom={0}>\n                  <Badge variant={currentSlide.badge.variant ?? \"default\"} className=\"w-fit\">\n                    {currentSlide.badge.label}\n                  </Badge>\n                </motion.div>\n              )}\n\n              {/* Heading */}\n              {currentSlide.heading && (\n                <motion.h1\n                  variants={textVariants}\n                  custom={1}\n                  className=\"text-4xl sm:text-5xl md:text-6xl lg:text-7xl font-bold text-white tracking-tight leading-[1.1]\"\n                >\n                  {currentSlide.heading}\n                </motion.h1>\n              )}\n\n              {/* Description */}\n              {currentSlide.description && (\n                <motion.p\n                  variants={textVariants}\n                  custom={2}\n                  className=\"text-base sm:text-lg md:text-xl text-white/70 max-w-xl font-light leading-relaxed\"\n                >\n                  {currentSlide.description}\n                </motion.p>\n              )}\n\n              {/* Buttons */}\n              {currentSlide.buttons && currentSlide.buttons.length > 0 && (\n                <motion.div\n                  variants={textVariants}\n                  custom={3}\n                  className=\"flex flex-wrap gap-3 mt-2\"\n                >\n                  {currentSlide.buttons.map((button) => (\n                    <Button\n                      key={button.id}\n                      variant={button.variant ?? \"default\"}\n                      asChild\n                      className={button.icon ? \"gap-2\" : undefined}\n                    >\n                      <a href={button.href}>\n                        {button.label}\n                        {button.icon}\n                      </a>\n                    </Button>\n                  ))}\n                </motion.div>\n              )}\n            </motion.div>\n          </AnimatePresence>\n        </div>\n\n        {/* Progress Bar */}\n        {autoPlay && slideCount > 1 && (\n          <div className=\"absolute bottom-0 left-0 right-0 h-1 bg-white/10\">\n            <motion.div\n              key={currentIndex}\n              className=\"h-full bg-white/50\"\n              initial={{ width: \"0%\" }}\n              animate={{ width: isPaused ? undefined : \"100%\" }}\n              transition={{\n                duration: interval / 1000,\n                ease: \"linear\",\n              }}\n            />\n          </div>\n        )}\n      </div>\n\n      {/* Next Slide Preview */}\n      {showPreview && nextSlide && slideCount > 1 && (\n        <motion.div\n          initial={{ opacity: 0, x: 20 }}\n          animate={{ opacity: 1, x: 0 }}\n          transition={{ delay: 0.5 }}\n          className=\"absolute bottom-20 lg:bottom-20 right-6 lg:right-8 z-10 hidden md:flex items-center gap-4 cursor-pointer group\"\n          onClick={() => paginate(1)}\n          onKeyDown={(e) => {\n            if (e.key === \"Enter\" || e.key === \" \") {\n              paginate(1);\n            }\n          }}\n          role=\"button\"\n          tabIndex={0}\n        >\n          <div className=\"text-right text-white opacity-0 group-hover:opacity-100 transition-all duration-300 transform translate-x-4 group-hover:translate-x-0\">\n            <p className=\"text-[10px] uppercase tracking-[0.2em] font-medium mb-1 text-white/50\">\n              Next\n            </p>\n            <p className=\"text-sm font-medium truncate max-w-[140px] text-white/80\">\n              {nextSlide.heading?.slice(0, 30) || \"Next Slide\"}\n            </p>\n          </div>\n\n          <div className=\"relative w-28 h-16 lg:w-36 lg:h-20 rounded-lg overflow-hidden border border-white/20 group-hover:border-white/40 transition-all duration-300 group-hover:scale-105\">\n            {nextSlide.image && (\n              <img\n                className=\"absolute inset-0 size-full object-cover opacity-60 group-hover:opacity-100 transition-all duration-500 group-hover:scale-110\"\n                src={nextSlide.image.src}\n                alt={nextSlide.image.alt}\n              />\n            )}\n            <div className=\"absolute inset-0 flex items-center justify-center bg-black/40 group-hover:bg-black/20 transition-colors duration-300\">\n              <div className=\"w-8 h-8 rounded-full bg-white/20 backdrop-blur-sm flex items-center justify-center group-hover:bg-white/30 transition-colors\">\n                <ArrowRight className=\"text-white size-4\" />\n              </div>\n            </div>\n          </div>\n        </motion.div>\n      )}\n\n      {/* Navigation Arrows */}\n      {showArrows && slideCount > 1 && (\n        <div className=\"absolute top-1/2 -translate-y-1/2 left-4 right-4 lg:left-8 lg:right-8 z-30 flex justify-between pointer-events-none\">\n          <button\n            type=\"button\"\n            onClick={() => paginate(-1)}\n            className=\"w-12 h-12 rounded-full bg-white/5 backdrop-blur-md border border-white/10 flex items-center justify-center text-white hover:bg-white/15 hover:border-white/30 transition-all duration-300 pointer-events-auto group\"\n          >\n            <ChevronLeft className=\"size-5 group-hover:-translate-x-0.5 transition-transform\" />\n          </button>\n          <button\n            type=\"button\"\n            onClick={() => paginate(1)}\n            className=\"w-12 h-12 rounded-full bg-white/5 backdrop-blur-md border border-white/10 flex items-center justify-center text-white hover:bg-white/15 hover:border-white/30 transition-all duration-300 pointer-events-auto group\"\n          >\n            <ChevronRight className=\"size-5 group-hover:translate-x-0.5 transition-transform\" />\n          </button>\n        </div>\n      )}\n\n      {/* Navigation Dots */}\n      {showDots && slideCount > 1 && (\n        <div className=\"absolute bottom-8 left-6 lg:left-8 z-30 flex items-center gap-2\">\n          <span className=\"text-[10px] text-white/40 font-mono mr-2\">\n            {String(currentIndex + 1).padStart(2, \"0\")} / {String(slideCount).padStart(2, \"0\")}\n          </span>\n          {slides.map((_, idx) => (\n            <button\n              type=\"button\"\n              key={idx}\n              onClick={() => goToSlide(idx)}\n              className={cn(\n                \"transition-all duration-500 rounded-full\",\n                idx === currentIndex ? \"w-8 h-2 bg-white\" : \"w-2 h-2 bg-white/30 hover:bg-white/50\"\n              )}\n            />\n          ))}\n        </div>\n      )}\n\n      {/* Slide Counter (Mobile) */}\n      <div className=\"absolute top-6 right-6 z-30 md:hidden\">\n        <span className=\"text-xs text-white/50 font-mono\">\n          {currentIndex + 1} / {slideCount}\n        </span>\n      </div>\n    </section>\n  );\n}\n",
      "type": "registry:component",
      "target": "components/beste/block/hero19.tsx"
    }
  ],
  "type": "registry:block"
}