diff options
author | Guilhem Moulin <guilhem@fripost.org> | 2024-01-31 22:52:47 +0100 |
---|---|---|
committer | Guilhem Moulin <guilhem@fripost.org> | 2024-01-31 22:54:22 +0100 |
commit | 672c48dba68da16b6698673a47f8d7488f5f9dbd (patch) | |
tree | 5cc3b457d4fec835c0b3e021612eef1fc5b59b27 /style2.css | |
parent | c9ad98b49ba630bc7db58733f6f18d5ec3865b10 (diff) |
example.html: Improve responsiveness on mobile devices.
Diffstat (limited to 'style2.css')
-rw-r--r-- | style2.css | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/style2.css b/style2.css new file mode 100644 index 0000000..dfeaee5 --- /dev/null +++ b/style2.css @@ -0,0 +1,50 @@ +body { + text-align: center; + max-width: 960px; + font-family: "Helvetica Neue", Arial, "Noto Sans", sans-serif; + padding: 0; + margin: 0 auto; + height: 100vh; + --margin-y: 1em; + --margin-x: 0; +} +#wrapper { + height: 100%; + display: flex; + flex-flow: column; + margin: 0 var(--margin-x); +} +#desc { + margin: var(--margin-y) 0; +} +#desc > p:first-child { + margin-top: 0; +} +#desc > p:last-child { + margin-bottom: 0; +} +#map { + border: 1px solid black; + width: 500px; + max-height: 600px; + margin: 0 auto var(--margin-y) auto; + flex: 1; +} +@media screen and (max-width: 500px) { + body { + --margin-x: .25em; + } + #map { + width: 100%; + } +} +@media screen and (max-height: 1280px) { + body { + --margin-y: .5em; + } +} +@media screen and (max-height: 600px) { + body { + --margin-y: .25em; + } +} |