personal_site/_sass/header.scss
2023-08-14 15:47:00 +01:00

116 lines
2.1 KiB
SCSS

@import "vars";
// The header with info about me
// gets displayed on the left in a wide layout and on the top in a narrow layout
header {
border-right: 2px solid #eee; //make a nice dividing line
position: fixed;
width: 240px;
height: 100vh;
padding-right: 30px;
padding-left: 30px;
flex: 0 0 240px;
display: flex;
flex-direction: column;
justify-content: center;
align-items: flex-end;
text-align: right;
top: 0px;
}
//a horizontal dividing line to swap in when we switch to mobile layout
header hr {
border:0px solid #eee;
width: 100%;
margin-top: 1em;
}
header .profile-pic-name {
text-align: center;
}
header .avatar {
max-width: 175px;
border-radius: 50%;
padding: 5px;
border: 1px solid #f2f3f3;
}
header h1 {
font-size: 2em;
}
header h1, header h2 {
font-family: $title_font_stack;
}
header img.icon {
height: 1em;
width: 1em;
margin-right: 0.5em;
margin-left: 0.5em;
flex: 0 0 auto;
}
header p.professional-links {
display: flex;
flex-direction: column;
}
header p.professional-links a {
display: flex;
align-items: center;
justify-content: space-between;
}
@media
only screen and (max-width: $horizontal_breakpoint),
only screen and (max-height: $vertical_breakpoint)
{
header {
position: relative;
width: 100%;
border: 0px;
text-align: center;
align-items: center;
height: auto;
padding-left: 20px;
padding-right: 20px;
}
// To squish the text together a bit in the mobile view.
header p {
margin-block: 0.25em;
}
header .avatar {
margin: auto;
}
nav {
display: flex;
flex-direction: row;
justify-content: center;
flex-wrap: wrap;
justify-content: center;
}
nav a {
margin-left: 1em;
}
header p.professional-links {
flex-direction: row;
}
header hr {
border-width:1px;
}
header p.professional-links a {
margin-left: 1em;
margin-right: 1em;
flex-wrap: wrap;
justify-content: center;
}
}