Juvenile female leaf-mimicking katydid (Tettigoniidae). Females have the large, sword-like, ovipositor at the end of their abdomen, and adults have full wings that cover the entire body.
I also ran into this, which I took in another part of Costa Rica a few years ago.