"use client"; import { useEffect, useState, type ReactNode } from "react"; type FlipCardProps = { front: ReactNode; back: ReactNode; frontLabel: string; backLabel: string; intervalMs?: number; onFlip?: (showingBack: boolean) => void; className?: string; }; const INTERACTIVE = "a, button, input, label, select, textarea"; export function FlipCard({ front, back, frontLabel, backLabel, intervalMs = 4500, onFlip, className = "", }: FlipCardProps) { const [flipped, setFlipped] = useState(false); const [paused, setPaused] = useState(false); const flip = () => { setFlipped(!flipped); onFlip?.(!flipped); }; useEffect(() => { if (paused || window.matchMedia("(prefers-reduced-motion: reduce)").matches) return; const id = window.setInterval(flip, intervalMs); return () => window.clearInterval(id); }); return (