layout fixes and improvements

This commit is contained in:
Tomáš Mládek 2020-10-20 19:13:36 +02:00
parent d32ad9bca3
commit bf423261ac

View file

@ -8,6 +8,8 @@ h1, h2, h3, h4, h5 {
body { body {
display: flex; display: flex;
width: 99vw;
margin: 0 auto;
} }
img { img {
@ -27,27 +29,19 @@ aside h1 {
font-variant: small-caps; font-variant: small-caps;
} }
main {
flex-grow: 1;
}
nav, main {
padding: 0 2em;
}
@media screen and (max-width: 800px) { @media screen and (max-width: 800px) {
body { body {
flex-direction: column-reverse; flex-direction: column-reverse;
} }
nav, main {
padding: 0 2em;
}
aside { aside {
border-top: 1px solid gray; border-top: 1px solid gray;
} }
aside h1 { aside h1 {
text-align: center; text-align: center;
} }
aside li { aside li {
display: inline-block; display: inline-block;
} }
@ -56,13 +50,21 @@ nav, main {
@media screen and (min-width: 800px) { @media screen and (min-width: 800px) {
aside { aside {
display: flex; display: flex;
flex: 0 0 18vw;
flex-direction: column; flex-direction: column;
justify-content: space-between; justify-content: space-between;
min-width: 15em;
width: 15em;
min-height: 100vh; min-height: 100vh;
border-right: 1px solid gray; border-right: 1px solid gray;
} }
nav {
padding: 0 1em;
}
main {
padding: 0 2em;
flex-grow: 1;
/* god dammit flexbox */
min-width: 1px;
}
} }
nav ul { nav ul {