html-resume/style.css

482 lines
8.8 KiB
CSS
Raw Normal View History

@page{
size: letter portrait;
margin: 0;
}
*{
box-sizing: border-box;
}
:root{
2018-10-04 19:23:49 +00:00
--page-width: 91.8rem;
--page-height: 118.8rem;
--main-width: 69.12rem;
--sidebar-width: calc(var(--page-width) - var(--main-width));
2018-10-04 19:23:49 +00:00
--decorator-horizontal-margin: 2.16rem;
2018-10-04 19:23:49 +00:00
--sidebar-horizontal-padding: 2.16rem;
/* XXX: using px for very good precision control */
2018-10-04 19:23:49 +00:00
--decorator-outer-offset-top: 1.125rem;
--decorator-outer-offset-left: -0.61875rem;
--decorator-border-width: 0.1125rem;
--decorator-outer-dim: 1.0125rem;
--decorator-border: 0.1125rem solid #ccc;
2018-10-04 19:23:49 +00:00
--row-blocks-padding-top: 0.749981rem;
--date-block-width: 6.48rem;
2018-10-04 19:23:49 +00:00
--main-blocks-title-icon-offset-left: -2.849929rem;
}
body{
width: var(--page-width);
height: var(--page-height);
margin: 0;
font-family: "Open Sans", sans-serif;
font-weight: 300;
2018-10-04 17:31:03 +00:00
line-height: 1.25;
color: #444;
hyphens: auto;
}
h1, h2, h3{
margin: 0;
2018-10-04 17:31:03 +00:00
color: #1a1a1a;
}
li{
list-style-type: none;
}
#main{
float: left;
width: var(--main-width);
2018-10-04 19:23:49 +00:00
padding: 2.7rem 2.7rem 0 2.7rem;
font-size: 1.124972rem;
}
#sidebar{
float: right;
position: relative; /* for disclaimer */
width: var(--sidebar-width);
height: 100%;
2018-10-04 23:17:48 +00:00
padding: 4.5rem var(--sidebar-horizontal-padding);
background-color: #f8f8f8;
2018-10-04 19:23:49 +00:00
font-size: 1.274968rem;
}
/* main */
/** big title **/
#title, h1, h2{
text-transform: uppercase;
}
#title{
position: relative;
2018-10-04 19:23:49 +00:00
left: 5.94rem;
margin-bottom: 3.24rem;
line-height: 1.2;
}
#title h1{
font-weight: 300;
2018-10-04 19:23:49 +00:00
font-size: 2.699933rem;
line-height: 1.5;
}
#title h1 strong{
2018-10-04 19:23:49 +00:00
margin: auto 0.299992rem auto 0.599985rem;
font-weight: 600;
}
.subtitle{
2018-10-04 19:23:49 +00:00
font-size: 1.19997rem;
}
/*** categorial blocks ***/
.main-block{
2018-10-04 19:23:49 +00:00
margin-top: 2.7rem;
}
#main h2{
position: relative;
top: var(--row-blocks-padding-top);
2018-10-04 19:23:49 +00:00
/* XXX: 0.05625rem for aligning fx printing */
left: calc((var(--date-block-width) + var(--decorator-horizontal-margin)));
font-weight: 400;
2018-10-04 19:23:49 +00:00
font-size: 1.649959rem;
color: #555;
}
#main h2 > i{
/* use absolute position to prevent icon's width from misaligning title */
/* assigning a fixed width here is no better due to needing to align decorator
line too */
position: absolute;
left: var(--main-blocks-title-icon-offset-left);
z-index: 1; /* over decorator line */
color: #444;
}
#main h2::after{ /* extends the decorator line */
height: calc(var(--row-blocks-padding-top) * 2);
position: relative;
top: calc(-1 * var(--row-blocks-padding-top));
2018-10-04 19:23:49 +00:00
/* XXX: 0.05625rem for aligning fx printing */
left: calc(-1 * var(--decorator-horizontal-margin));
display: block;
border-left: var(--decorator-border);
z-index: 0;
line-height: 0;
font-size: 0;
content: ' ';
}
/**** minor tweaks on the icon fonts ****/
#main h2 > .fa-graduation-cap{
2018-10-04 19:23:49 +00:00
left: calc(var(--main-blocks-title-icon-offset-left) - 0.299992rem);
top: 0.299992rem;
}
#main h2 > .fa-suitcase{
2018-10-04 19:23:49 +00:00
top: 0.149996rem;
}
#main h2 > .fa-folder-open{
2018-10-04 19:23:49 +00:00
top: 0.224994rem;
}
/**** individual row blocks (date - decorator - details) ****/
.blocks{
display: flex;
flex-flow: row nowrap;
}
.blocks > div{
padding-top: var(--row-blocks-padding-top);
}
.date{
flex: 0 0 var(--date-block-width);
2018-10-04 19:23:49 +00:00
padding-top: calc(var(--row-blocks-padding-top) + 0.374991rem) !important;
padding-right: var(--decorator-horizontal-margin);
2018-10-04 19:23:49 +00:00
font-size: 1.049974rem;
text-align: right;
line-height: 1;
}
.date span{
display: block;
}
.date span:nth-child(2)::before{
position: relative;
2018-10-04 19:23:49 +00:00
top: 0.149996rem;
right: 0.824979rem;
display: block;
2018-10-04 19:23:49 +00:00
height: 1.499963rem;
content: '|';
}
.decorator{
flex: 0 0 0;
position: relative;
2018-10-04 19:23:49 +00:00
width: 0.299992rem;
min-height: 100%;
border-left: var(--decorator-border);
}
/*
* XXX: Use two filled circles to achieve the circle-with-white-border effect.
* The normal technique of only using one pseudo element and
2018-10-04 19:23:49 +00:00
* border: 0.1125rem solid white; style makes firefox erroneously either:
* 1) overflows the grayshade background (if no background-clip is set), or
* 2) shows decorator line which should've been masked by the white border
*
*/
.decorator::before{
position: absolute;
top: var(--decorator-outer-offset-top);
left: var(--decorator-outer-offset-left);
content: ' ';
display: block;
width: var(--decorator-outer-dim);
height: var(--decorator-outer-dim);
border-radius: calc(var(--decorator-outer-dim) / 2);
background-color: #fff;
}
.decorator::after{
position: absolute;
top: calc(var(--decorator-outer-offset-top) + var(--decorator-border-width));
left: calc(var(--decorator-outer-offset-left) + var(--decorator-border-width));
content: ' ';
display: block;
width: calc(var(--decorator-outer-dim) - (var(--decorator-border-width) * 2));
height: calc(var(--decorator-outer-dim) - (var(--decorator-border-width) * 2));
border-radius: calc((var(--decorator-outer-dim) - (var(--decorator-border-width) * 2)) / 2);
background-color: #555;
}
.blocks:last-child .decorator{ /* slightly shortens it */
2018-10-04 19:23:49 +00:00
margin-bottom: 2.7rem;
}
/***** fine-tunes on the details block where the real juice is *****/
.details{
flex: 1 0 0;
padding-left: var(--decorator-horizontal-margin);
2018-10-04 19:23:49 +00:00
padding-top: calc(var(--row-blocks-padding-top) - 0.074998rem) !important; /* not sure why but this is needed for better alignment */
}
.details header{
2018-10-04 17:31:03 +00:00
color: #1a1a1a;
2018-10-04 19:23:49 +00:00
margin-bottom: 1.9125rem;
}
.details h3{
2018-10-04 19:23:49 +00:00
font-size: 1.349966rem;
}
.main-block:not(.concise) .details div{
2018-10-04 19:23:49 +00:00
/* margin: 1.944rem 0 1.08rem 0; */
}
.main-block:not(.concise) .blocks:last-child .details div{
margin-bottom: 0;
}
.main-block.concise .details div:not(.concise){
/* use padding to work around the fact that margin doesn't affect floated
neighboring elements */
2018-10-04 19:23:49 +00:00
padding: 0.54rem 0 0.756rem 0;
}
.details .place{
float: left;
2018-10-04 19:23:49 +00:00
font-size: 1.124972rem;
2018-10-02 05:08:55 +00:00
font-weight: 400;
}
.details .location{
float: right;
2018-10-02 05:08:55 +00:00
font-family: 'Open Sans', sans-serif;
}
.details div{
clear: both;
}
.details .location::before{
display: inline-block;
position: relative;
2018-10-04 19:23:49 +00:00
right: 0.449989rem;
top: 0.037499rem;
font-style: normal;
text-decoration: inherit;
2018-10-02 04:00:34 +00:00
content: "\f3c5";
2018-10-02 05:08:55 +00:00
font-family: 'Font Awesome 5 Free';
}
/***** fine-tunes on the lists... *****/
#main ul{
2018-10-04 19:23:49 +00:00
padding-left: 0.756rem;
margin: 0.864rem 0;
}
#main li{
2018-10-04 19:23:49 +00:00
margin: 0.378rem 0;
}
/****** customize list symbol style ******/
#main li::before{
position: relative;
2018-10-04 19:23:49 +00:00
margin-left: -0.637484rem;
content: '• ';
}
.details .concise ul{
margin: 0 !important;
-webkit-columns: 2;
-moz-columns: 2;
columns: 2;
}
.details .concise li{
margin: 0 !important;
}
.details .concise li{
margin-left: 0 !important;
}
/* sidebar */
#sidebar h1{
font-weight: 400;
2018-10-04 19:23:49 +00:00
font-size: 1.649959rem;
}
.side-block{
2018-10-04 23:17:48 +00:00
margin-top: 6.5rem;
}
#contact ul{
2018-10-04 19:23:49 +00:00
margin-top: 0.54rem;
padding-left: 0;
2018-10-04 23:17:48 +00:00
font-family: "Inconsolata", monospace;
font-weight: 400;
line-height: 1.75;
2018-10-04 23:17:48 +00:00
font-size: 1.3rem;
}
#contact li > i{
2018-10-04 19:23:49 +00:00
width: 1.349966rem; /* for text alignment */
text-align: right;
}
.skills{
line-height: 1.5;
}
.skills ul{
2018-10-04 19:23:49 +00:00
margin: 0.54rem 0 1.62rem;
padding: 0;
}
#disclaimer{
position: absolute;
bottom: var(--sidebar-horizontal-padding);
right: var(--sidebar-horizontal-padding);
2018-10-04 19:23:49 +00:00
font-size: 1.124972rem;
font-style: italic;
line-height: 1.1;
text-align: right;
color: #777;
}
#disclaimer code{
color: #666;
font-family: "Source Code Pro";
font-weight: 400;
font-style: normal;
}
2018-08-15 23:29:13 +00:00
2018-08-15 23:31:39 +00:00
/* make links functional for web,
* but not distracting for print
*/
2018-10-04 17:31:03 +00:00
2018-08-15 23:29:13 +00:00
a[href]{
text-decoration: none;
2018-10-04 17:31:03 +00:00
color: #1a1a1a;
2018-08-15 23:29:13 +00:00
}
2018-08-15 23:31:39 +00:00
/* make web version resemble printable page
*/
body{
background-color: grey;
}
body > *{
background-color: white;
}
#main{
height: var(--page-height);
}
#sidebar{
height: var(--page-height);
}
2018-10-02 04:00:34 +00:00
.recommendation {
2018-10-04 19:23:49 +00:00
margin: 1.5em 0.0rem;
2018-10-02 04:00:34 +00:00
font-style: italic;
}
.recommendation > div {
font-style: normal;
margin: 0.4em 0.6em;
}
.recommendation > div:before {
content: "- ";
position: absolute;
left: 1.8em;
2018-10-02 18:06:05 +00:00
}
svg.ts-logo {
fill: #444444;
2018-10-04 19:23:49 +00:00
width: 1.125rem;
2018-10-02 18:06:05 +00:00
position: relative;
2018-10-04 19:23:49 +00:00
top: 0.1125rem;
2018-10-04 20:07:10 +00:00
}
2018-10-04 17:31:03 +00:00
@media not print {
a[href]{
color: #444;
}
a[href]:hover{
text-decoration: underline;
}
}
@media print {
2018-10-04 19:23:49 +00:00
:root {
2018-10-05 04:07:14 +00:00
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
2018-10-04 19:23:49 +00:00
font-size: 8.888888889px;
}
2018-10-04 17:31:03 +00:00
#sidebar {
background-color: #e3e3e3;
}
2018-10-04 20:07:10 +00:00
.no-print {
display:none;
}
2018-10-22 21:29:49 +00:00
2018-10-04 17:31:03 +00:00
}
2018-10-04 20:07:10 +00:00
.source-link {
position: fixed;
bottom: 0;
right: 10rem;
2018-10-04 23:17:48 +00:00
background-color: #214827de;
2018-10-04 20:07:10 +00:00
padding: 0.5rem 1.5rem 0.5rem 1.5rem;
font-size: 1.1rem;
2018-10-04 22:27:38 +00:00
color: #FFF;
2018-10-04 20:07:10 +00:00
border-radius: 4px 4px 0 0;
}
.source-link a {
2018-10-04 22:27:38 +00:00
color: #DDD;
2018-10-22 21:29:49 +00:00
}
2018-10-22 23:03:11 +00:00
.control-buttons {
2018-10-22 21:29:49 +00:00
position: absolute;
2018-10-22 23:03:11 +00:00
padding: 0.15em 0.2em;
left: 0;
top: 0;
margin: 0.8em;
font-size: 2.1rem;
border: dashed #28582fed 0.1em;
}
.control-buttons a {
margin: 0.2em;
}
.control-buttons a {
color: #28582fed;
margin: 0.2em;
2018-10-04 20:07:10 +00:00
}