The 24-hour day is not fixed but slowly stretching, and in the dinosaurs' time it was shorter: the Moon's pull is gently braking Earth's spin, so a day back then ran about 23.5 hours, and far shorter deeper in the past
Earth’s days are slowly stretching—as the Moon drifts 3.8 cm yearly, a dinosaur-era day was only 23.5 hours.