:root {
  --text-primary: #000000;
  --text-secondary: #696969;
  --text-muted: #525252;
  --accent-color: #a07d0b;
  --tag-bg: #eeeeee;
  --tag-text: #999999;
}

body {
  font-family: "EB Garamond", serif;
  max-width: 120ch;
  padding: 2ch;
  margin-left: auto;
  margin-right: auto;
  font-size: large;
  text-align: justify;
}

h2 {
  display: flex;
  align-items: center;
}

h2:after {
  content: "";
  margin-top: 1rem;
  margin-left: 0.5ch;
  flex: 1;
  height: 1px;
  background-color: var(--text-secondary);
}

.external-links {
  margin-top: -1rem;
  padding-left: 0;
}

.external-links > li {
  display: inline-block;
  border-right: 1px solid var(--text-primary);
  padding-left: 1ch;
  padding-right: 1ch;
}

.external-links > li:first-child {
  border-right: 1px solid var(--text-primary);
  padding-right: 1ch;
  padding-left: 0ch;
}

.external-links > li:last-child {
  border: none;
  padding-left: 1ch;
}

.external-links > li > a {
  color: var(--text-primary);
}

.external-links > li > a > i {
  margin-right: 0.5ch;
}

.external-links > li > a:link,
a:visited {
  text-decoration: none;
}

#education > ul,
#experience > ul,
#other > ul {
  list-style-type: none;
  padding: 0;
  margin-top: -0.5rem;
}

#education > ul > li,
#experience > ul > li,
#other > ul > li {
  display: block;
  margin-bottom: 1rem;
}

#education > ul > li:last-child,
#experience > ul > li:last-child,
#other > ul > li:last-child {
  margin-bottom: 0rem;
}

#education > ul > li > .title,
#experience > ul > li > .title,
#other > ul > li > .title {
  margin-bottom: 0.2rem;
}

#education > ul > li > .title > span,
#experience > ul > li > .title > span,
#other > ul > li > .title > span {
  color: var(--text-muted);
  font-weight: bold;
}

#education > ul > li > .description,
#other > ul > li > .description {
  margin-left: 1rem;
  color: var(--text-secondary);
}

#education > ul > li > .description > span,
#other > ul > li > .description > span {
  margin-bottom: 0.2rem;
  display: block;
}

#experience .activity > ul {
  color: var(--text-secondary);
  list-style-type: square;
}

#experience .activity > ul > li {
  margin: 0.2rem 0;
}

#experience .company {
  color: var(--text-secondary);
  font-size: medium;
  text-align: justify;
}

#experience .company > ul {
  list-style-type: none;
  padding: 0;
  margin-bottom: 0.2rem;
}

#education .thesis {
  color: var(--text-secondary);
  margin-left: 1rem;
  font-weight: bold;
}

.position {
  font-weight: normal;
}

footer {
  margin-top: 2rem;
  font-size: medium;
  color: var(--text-secondary);
  font-weight: bold;
}

.link > a,
.link > button {
  color: var(--accent-color);
  font-weight: bold;
}

.link > a:link,
a:visited {
  text-decoration: none;
}

.link > button {
  background: none !important;
  border: none;
  padding: 0 !important;
  cursor: pointer;
  font: inherit;
}

.tags {
  list-style: none;
  margin: 0;
  overflow: hidden;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
}

.tag {
  background: var(--tag-bg);
  border-radius: 0.5rem;
  color: var(--tag-text);
  display: inline-block;
  height: 1.5rem;
  line-height: 1.5rem;
  padding: 0 0.5rem 0 0.5rem;
  position: relative;
  margin: 0 0.5rem 0.5rem 0;
  text-decoration: none;
}

.competencies {
  color: var(--text-secondary);
  list-style-type: square;
  line-height: 1.5rem;
}

.date {
  display: inline;
  float: right;
}

@media screen and (max-width: 811px) {
  .date {
    display: block;
    float: none;
  }

  .tags {
    justify-content: space-between;
  }

  .external-links {
    margin-top: -1rem;
    padding-left: 0;
  }

  .external-links > li {
    display: block;
    border-right: none;
    padding-left: 0;
    padding-right: 0;
  }

  .external-links > li:first-child {
    border-right: none;
    padding-right: 0;
    padding-left: 0;
  }

  .external-links > li:last-child {
    border: none;
    padding-left: 0;
  }
}

@media print {
  @page {
    size: A4;
    margin: 10mm;
  }

  .date {
    display: block;
    float: none;
  }

  #experience {
    break-before: page;
    page-break-before: always;
  }

  #other {
    break-before: page;
    page-break-before: always;
  }

  #experience .activity > ul > li {
    break-inside: avoid;
    page-break-inside: avoid;
  }

  #experience > ul > li {
    break-inside: avoid;
    page-break-inside: avoid;
  }

  footer {
    display: none;
  }
}
