JSFiddle - React, Tailwind, and code Playground
by jonahe
HTML
<script src="https://code.jquery.com/jquery-3.4.1.slim.js"></script>
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.16.0/umd/popper.js"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/js/bootstrap.js"></script>
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.css">
<!--
Bootstrap docs: https://getbootstrap.com/docs
-->
<div class="position-absolute splash-wrapper orientation-landscape d-flex align-items-center w-100">
<div class="d-flex flex-column">
<span class="d-flex splash-sm-title-header w-75">
The title of the program is THIS
</span>
<span class="d-flex splash-sm-title-subheader">
The sub-title of the program is THIS, and it's often longer for some reason, possibly spanning a 2-3 lines.
</span>
</div>
</div>
CSS
:root {
--header-landscape-font-size_width_based: clamp(20px, 12.3vw, 12.3vw);
--header-landscape-font-size_height_based: clamp(20px, 19.3vh, 19.3vh);
}
.splash-sm-title-header {
line-height: 1.1;
font-size: min(var(--header-landscape-font-size_width_based), var(--header-landscape-font-size_height_based));
text-align: center;
}
.splash-sm-title-subheader {
}