Dating is not against the law, regardless of age. However, pornography and actual sex can still get you into trouble.
Until you turn 18, any image of you in a partially or completely unclothed state is a felony under federal law. You dressed normally would be okay, in a swimsuit is probably not. When in doubt, assume it's not legal. If the intent is to turn him on sexually, then it absolutely is not okay. Any pornographic image of someone under 18 is legally considered to be child pornography, even if you are only a day short of your 18th birthday. The government definition of child pornography errs on the side of protecting children, so taking any chances on this is almost certainly crossing the line.
Creating child pornography (even a self-portrait) is worth 10 or more years in prison without possibility of parole. It also would make you a sex offender. Possessing child pornography is worth 3-5 years per image or file. If you take a naked self-portrait (or do a web cam chat naked) you could go to prison for 10 years, and your boyfriend for 5-10 years. The law makes no distinction between a 40 year old taking pictures of children and a child snapping a self-portrait in the mirror. Don't do it, it's not worth the risks.
Dating is legal in every state, but different states define sex differently; Most define it as genital contact, but some go so far as to include some times of hugs and/or kisses. Safer to keep it chaste.
Actual sex would depend on both state age of consent and federal age of consent. Since you're in different states, you must consider both states AND the federal laws on the matter. In Ohio, you would be legal to have sex with your boyfriend right now. But in Pennsylvania, since he is over 18 and you are not, sex would be a crime. And under federal law, sex would also be a crime.
Pennsylvania sets the age of consent at 16, but they also have a corrupting minors law on the books that effectively raises the age to 18. Pennsylvania is one of the states were two 17 year olds can consent to eachother, but the day one of them turns 18, sex becomes statutory rape until the other turns 18 as well due to that corrupting a minor law. Corrupting a minor is a first degree misdemeanor.
Ohio is more lenient. Ohio age of consent is 16, with no odd legal booby-traps. A clear read of the law would seem to imply that visiting your boyfriend in Ohio would let you have sex. It doesn't. That brings us to federal laws.
There are two federal laws that impact you directly.
One is the federal age of consent, which is set at 18 years of age. Those under 18 have a 4 year Romeo & Juliet exemption, that you don't qualify for, since your boyfriend is over 21. That's actually the more minor of the two problem laws at the federal level. The federal age of consent kicks in on federal land (national parks, federal courthouses, etc) AND when you cross a state border in some fashion. Use of the internet, any telephone (land or cell) or the U.S. Mail to arrange to meet for sex is considered to cross state borders.
The other federal problem for your relationship is that it is a felony to cross any state or national border to engage in behavior that is illegal in your place of residence.
My advice to you is to wait the 6 months until your 18th birthday before you do anything more sexually provocative than talk, fully clothed.