Does anyone know of a CSS code that can effectively target both iPad and desktop devices with a max-width of 768?
I attempted the following code, however it seems to only work for desktops:
@media only screen and (max-width: 768px)
Due to this limitation, I adjusted the code specifically for iPads:
@media only screen and (device-width: 768px)
Unfortunately, having the same exact code inside both media queries is not an ideal solution.
I also experimented with this code:
@media only screen and (max-width: 767px) or (device-width: 768px)
Surprisingly, the above code did not work as expected - it functions on desktop regardless of width, but not on iPad. Quite perplexing.
Any suggestions on how to efficiently target both iPad and desktop using the same media query?