lynnespace/assets/style.css
2021-05-02 18:41:01 +10:00

213 lines
No EOL
3.5 KiB
CSS

* {
box-sizing: border-box;
}
body {
font-family: sans-serif;
margin: 0;
display: grid;
grid-template-columns: max(325px, 15%) auto;
background: #fafafa;
}
h1, h2, h3, h4, h5, h6 {
font-family: "Open Sans", sans-serif;
}
main article h1 a,
main article h2 a,
main article h3 a,
main article h4 a,
main article h5 a,
main article h6 a {
color: inherit;
text-decoration: none;
}
h1, h2, h3 {
font-weight: 400;
}
h1 {
font-size: 3em;
text-align: center;
/*noinspection CssInvalidPropertyValue*/
text-decoration: underline mediumpurple dotted 5px;
}
h2 {
font-size: 1.6em;
}
main {
box-shadow: 0 0 40px black;
z-index: 2;
}
main article {
max-width: 1800px;
padding: 0 50px 30px;
margin: 0 auto;
background: #fafafa;
min-height: 100%;
overflow: auto;
font-size: 1.1em;
}
main article h2,
main article h3 {
border-left: 5px solid mediumpurple;
padding-left: 5px;
margin-left: -10px;
}
main article a {
color: #60a;
text-decoration-style: dotted;
text-decoration-color: transparent;
transition: 0.2s all;
}
main article a:hover {
text-decoration-color: unset;
}
p {
line-height: 1.5em;
}
header {
/* sidebar */
position: sticky;
top: 0;
background: #333;
height: 100vh;
transition: 0.2s all;
}
header::after {
/* will use webp with jpeg fallback when
https://developer.mozilla.org/en-US/docs/Web/CSS/image()#browser_compatibility becomes a thing, until then, it's jpeg
only for now :c */
display: block;
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
z-index: -1;
/*noinspection CssInvalidFunction*/
background: linear-gradient(to bottom, #333, #333 10%, 70%, transparent),
url("/assets/img/background.jpeg") no-repeat bottom center/cover,
#333;
filter: blur(5px) saturate(75%);
content: "";
}
#hamburger {
display: none;
position: fixed;
top: 10px;
left: 10px;
padding: 10px;
background: #fafafa;
color: mediumpurple;
border-radius: 10px;
height: 27px;
width: 27px;
z-index: 3;
box-sizing: content-box;
}
#hb-icon {
height: 100%;
width: 100%;
background: linear-gradient( to bottom, mediumpurple, mediumpurple 10%, #fafafa 10%, #fafafa 45%, mediumpurple 45%, mediumpurple 55%, #fafafa 55%, #fafafa 90%, mediumpurple 90%, mediumpurple 100% );
}
nav a {
color: white;
}
nav a {
padding: 10px 0;
display: block;
width: 100%;
text-align: center;
text-decoration: none;
font-size: 1.5em;
transition: 0.2s all;
position: relative;
}
nav a::before {
width: 5px;
top: 0;
bottom: 0;
left: -5px;
background: mediumpurple;
content: "";
display: block;
position: absolute;
transition: 0.2s all;
}
nav a:hover,
nav a.current {
background: #00000044;
}
nav a:hover::before,
nav a.current::before {
left: 0;
}
#logo {
object-fit: contain;
display: block;
width: min(100%, 150px);
height: auto;
margin: 30px auto 50px auto;
}
#bune {
height: max(200px, 10vh);
display: block;
margin: 50px auto 0;
}
.project {
border-top: thin grey solid;
}
.project:last-of-type {
border-bottom: thin grey solid;
}
.project p {
margin-bottom: 0.5em;
}
.project-footer {
font-size: 0.85em;
padding-bottom: 1em;
}
.project-footer a {
font-style: italic;
}
/* mobile tweaks */
@media only screen and (min-device-width : 320px) and (max-device-width : 480px) {
main {
width: 100vw;
box-shadow: none;
}
main article {
padding: 0 20px 30px;
}
h1 {
font-size: 2.5em;
}
h2 {
font-size: 1.5em;
}
header {
position: fixed;
left: -100vw;
width: 100vw;
z-index: 3;
}
header.active {
left: 0;
}
#hamburger {
display: inline-block;
touch-action: manipulation;
}
}