I've been searching through various discussions and questions, but I have not found the exact solution to my issue.
The website I created fits within a 960px block for optimal viewing on iPads, but now I need a stylesheet to be applied when the screen size is smaller than 480px for mobile devices.
I seem to be encountering problems with the meta viewport settings. I have tried different methods, such as using "
<link rel="stylesheet" href="/templates/dervans/css/mobile.css" media="screen and (max-device-width: 480px)" />
" in the header along with "<meta name='viewport' content='width=device-width, initial-scale=1'>
". This approach works, but it causes the website to break on larger mobile devices like iPads that exceed 480px in width. Removing the viewport tag solves the issue on iPads, but then the mobile CSS does not apply.
Do you have any suggestions or solutions?