body { font-family: 'Ariel', sans-serif; } .files { display: flex; flex-wrap: wrap; } .file { display: flex; margin: 1em; border: 1px solid #449dfc; border-radius: 5px; padding: 1em; } .thumbnail { max-width: 320px; margin: 1em; } img { max-width: 100%; } [type="submit"] { border-radius: 1em; margin: 1em; padding: 1em; } .uploadform { display: flex; margin: 1em; background-color: #e5f0fc; border: 1px solid #449dfc; border-radius: 5px; padding: 1em; } /* https://benmarshall.me/styling-file-inputs/ */ [type="file"] { border: 0; clip: rect(0, 0, 0, 0); height: 1px; overflow: hidden; padding: 0; position: absolute !important; white-space: nowrap; width: 1px; } [type="file"] + label { background-color: rgb(0, 86, 112); border-radius: 1em; color: #fff; cursor: pointer; display: inline-block; padding: 1em; margin: 1em; transition: background-color 0.3s; } [type="file"]:focus + label, [type="file"] + label:hover { background-color: #67b0ff; } [type="file"]:focus + label { outline: 1px dotted #000; outline: -webkit-focus-ring-color auto 5px; } @media screen and (max-width: 980px) { /* This is the screen width of a OnePlus 5t */ body { font-size: xx-large; } [type="submit"] { font-size: xx-large; width: 100%; } .uploadform { display: flex; } [type="file"] + label { width: 100%; } .thumbnail { max-width: 100%; margin: 1em; } .file { display: flex; flex-direction: column; width: 100%; } }