import React from 'react';
import { motion } from 'framer-motion';
type RevealProps = {
  children: React.ReactNode;
  delay?: number;
  className?: string;
};
export function Reveal({ children, delay = 0, className }: RevealProps) {
  return (
    <motion.div
      className={className}
      initial={{
        opacity: 0,
        y: 24
      }}
      whileInView={{
        opacity: 1,
        y: 0
      }}
      viewport={{
        once: true,
        margin: '-80px'
      }}
      transition={{
        duration: 0.6,
        delay,
        ease: [0.21, 0.47, 0.32, 0.98]
      }}>
      
      {children}
    </motion.div>);

}