If you want to discriminate between mobile and PC, you can use CSS @media queries, like:
@media all and (max-width: 767px) {
// CSS rules for viewport that is narrower than 780px
}
For example:
@media all and (max-width: 767px) {
.pagetitle, .menutitle {
font-size: 12px;
}
}
However, CSS media queries should not be solely determined by device dimensions alone — sometimes it makes more sense to tailor the break points based on your sire's content or design, in which you select arbitrary width(s) where the layout switch occurs.
You can try using viewport units: vh, vw, vmin and vmax. They are declared as numerical values although they technically represent percentage of the viewport measurement they are referring to.
For example, if your screen is 1600*768 in resolution, using a font size of:
5vw
will give you 80px—5% of the viewport width
5vh
will give you 38.4px (likely rounded to 38px by rendering)—5% of the viewport height
5vmax
will give you 80px—5% of the longest dimension (in this case, horizontal measurement of 1600px)
5vmin
will give you 38.4px—5% of the shorter dimension (in this case, vertical measurement of 768px)
Note that the last two units are sensitive to device/viewport orientation :)