How to calculate ideal height with css calc();

Like an element got

height: 100vh;

How to cauclate the ideal

min-height

and

max-height

in pixel for mobile with css calc()?

Thanks.

hard to understand this post.
If the element is 100vh, then that means you want it to cover the viewport height.
Does that not work for mobile as-is?

anyway, in case this helps:

1 Like