@import url('https://fonts.googleapis.com/css2?family=Fira+Code:wght@300;400;500;600;700&display=swap');

:root {
  --background-color: #FFF;
  --foreground-color: #ff1a3c;
  --text-color: #1f2229;
}

@media (prefers-color-scheme: dark) {
  :root {
    --background-color: #1f2229;
    --foreground-color: #ff1a3c;
    --text-color: #FFF;
  }
}

* {
  box-sizing: border-box;
}

*::selection {
  color: var(--background-color);
  background: var(--foreground-color);
}

*::-moz-selection {
  color: var(--background-color);
  background: var(--foreground-color);
}

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  background-color: var(--background-color);
  color: var(--text-color);
  font-family: "Fira Code", Monaco, Consolas, "Ubuntu Mono", monospace;
}

@keyframes pageEnter {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#root {
  width: 100%;
  max-width: 820px;
  margin: 0 auto;
  padding: 40px 40px 50px;
}

/* Header */

header {
  width: 100%;
  display: flex;
  flex-direction: row;
  background-image: repeating-linear-gradient(90deg, var(--foreground-color), var(--foreground-color) 2px, transparent 0px, transparent 8px);
  justify-content: space-between;
}

header .title {
  background-color: var(--foreground-color);
  color: var(--background-color);
  padding: 4px 7px 4px 8px;
  font-size: 1em;
  line-height: 28px;
  text-decoration: none;
  font-weight: 400;
}

header #language-switcher {
  display: block;
  margin: 0;
  padding: 0;
  flex-shrink: 0;
}

header #language-switcher a {
  display: inline-block;
  padding: 4px 8px;
  background-color: var(--background-color);
  border: 2px solid var(--foreground-color);
  line-height: 24px;
  cursor: default;
  color: var(--foreground-color);
  text-decoration: none;
  font-weight: 300;
}

header #language-switcher a:hover {
  color: var(--background-color);
  background-color: var(--foreground-color);
  font-weight: 400;
}

/* Menu */

menu {
  display: block;
  width: 100%;
  margin: 15px 0 0 0;
  padding: 0;
}

menu a {
  position: relative;
  padding: 0 .75em;
  margin-right: 25px;
  line-height: 28px;
  background-color: var(--background-color);
  color: var(--text-color);
  text-decoration: none;
  cursor: default;
}

menu a.active,
menu a:hover {
  color: var(--foreground-color);
  font-weight: bold;
}

menu a.active:before,
menu a:hover:before {
  position: absolute;
  left: -2px;
  content: "[";
  color: var(--foreground-color);
  font-weight: bold;
}

menu a.active:after,
menu a:hover:after {
  position: absolute;
  content: "]";
  right: -2px;
  color: var(--foreground-color);
  font-weight: bold;
}

/* Figures */

figure {
  margin-bottom: 2.5em;
}

figure figcaption {
  font-size: .8em;
  font-style: italic;
  text-align: center;
}

figure figcaption a {
  color: var(--text-color);
  text-decoration: none;
  border-bottom: 2px solid var(--foreground-color);
  cursor: default;
}

figure figcaption a:hover {
  color: var(--foreground-color);
  font-weight: 600;
}

/* Footer */

footer {
  margin-top: 50px;
  border-top: 3px dotted var(--foreground-color);
  font-size: .9em;
  text-align: center;
}

footer:before {
  content: "";
  display: block;
  width: 100%;
  margin: 2px 0 45px 0;
  border-top: 3px dotted var(--foreground-color);
}

footer .social-links {
  display: flex;
  flex-direction: row;
  justify-content: center;
  gap: 30px;
  margin-bottom: 20px;
}

footer .social-links a {
  text-decoration: none;
  color: var(--foreground-color);
}

footer .social-links a .w {
  color: var(--text-color);
  padding: 0 2px;
}

footer .social-links a:hover .w {
  color: var(--foreground-color);
}

footer .contact-me-plz {
  display: block;
  text-decoration: none;
  color: var(--foreground-color);
}

footer .contact-me-plz .w {
  color: var(--text-color);
  padding: 0 2px;
}

/* Main content */

main {
  width: 100%;
  animation: pageEnter 0.3s ease-out both;
}

main h1 {
  margin: 60px 0 30px;
  font-size: 1.2em;
  color: var(--foreground-color);
  font-weight: 600;
  border-bottom: 3px dotted var(--foreground-color);
}

main h1:after {
  content: "";
  display: block;
  width: 100%;
  margin: 10px 0 2px 0;
  border-bottom: 3px dotted var(--foreground-color);
}

main h1 .back-arrow {
  float: right;
  transition-duration: .15s;
  color: var(--foreground-color);
  text-decoration: none;
}

main h1 .back-arrow:hover {
  padding-right: .4em;
  font-weight: 700;
}

main h1 .back-arrow:hover span {
  font-weight: 500;
}

main h1 .back-arrow:active {
  padding-right: 1em;
}

main h1 .back-arrow span {
  padding-left: .5em;
  font-size: .8em;
  font-weight: 500;
}

main h2 {
  position: relative;
  margin-top: 40px;
  font-weight: 700;
  font-size: 1.2em;
}

main h2:before {
  content: "\2591";
  position: absolute;
  top: -2px;
  left: -20px;
  color: var(--foreground-color);
  cursor: default;
}

main .open-to-work {
  margin: 30px 0 15px 0;
  padding: 12px 20px;
  border-left: 3px solid var(--foreground-color);
  color: var(--foreground-color);
  font-weight: 500;
  font-size: .95em;
  text-indent: 0;
}

main h3.section-divider {
  margin-top: 60px;
  padding-top: 20px;
  border-top: 1px dotted var(--foreground-color);
  font-size: 1em;
  font-weight: 400;
  color: var(--foreground-color);
}

main h4 {
  margin: 30px 0 0 0;
}

main p.wip {
  font-style: italic;
  opacity: 0.7;
}

main p {
  font-size: .95em;
  line-height: 1.7em;
  font-weight: 400;
  text-indent: 2em;
}

main p a {
  color: var(--text-color);
  text-decoration: none;
  border-bottom: 2px solid var(--foreground-color);
  cursor: default;
}

main p a:hover {
  color: var(--foreground-color);
  font-weight: 600;
}

main p a.open-arrow {
  border: none;
  color: var(--foreground-color);
  font-size: 1.3em;
  padding-left: .2em;
  font-weight: 300;
  vertical-align: bottom;
  margin-left: .5em;
  transition-duration: .15s;
}

main p a.open-arrow:hover {
  padding-left: .4em;
  font-weight: 700;
}

main p a.open-arrow:hover span {
  font-weight: 500;
}

main p a.open-arrow:active {
  padding-left: 1em;
}

main p a.open-arrow span {
  padding-left: .5em;
  font-size: .8em;
  vertical-align: bottom;
  font-weight: 400;
}

main ul {
  list-style-type: none;
  margin-top: 5px;
}

main ul li {
  position: relative;
  width: fit-content;
  text-decoration-style: dotted;
  text-decoration: var(--foreground-color);
}

main ul li:before {
  content: "_";
  position: absolute;
  left: -.7em;
  color: var(--foreground-color);
  cursor: default;
}

main ul li > .wtf-comment,
main ul li > .serious-comment {
  display: none;
}

main ul li:hover > .wtf-comment,
main ul li:hover > .serious-comment {
  display: inline;
}

main ul li .serious-comment {
  position: absolute;
  color: var(--foreground-color);
  white-space: nowrap;
  left: 100%;
}

main ul li .serious-comment:before {
  content: "::";
}

main ul li .wtf-comment {
  position: absolute;
  color: var(--foreground-color);
  transform-origin: left center;
  white-space: nowrap;
}

main ul li .wtf-comment.wtf-1 {
  left: 100%;
  transform: rotate(-2deg);
}

main ul li .wtf-comment.wtf-2 {
  left: 50%;
  top: -70%;
  transform: rotate(1.5deg);
}

main ul li .wtf-comment.wtf-3 {
  left: 100%;
  transform: rotate(1deg);
}

main ul li .wtf-comment.wtf-4 {
  left: 80%;
  top: -70%;
  transform: rotate(4deg);
}

main ul li .wtf-comment.wtf-5 {
  left: 100%;
  transform: rotate(-1deg);
}

/* Comment */

.comment {
  display: inline-block;
  position: relative;
  margin-left: 40px;
  font-size: .8em;
  font-style: italic;
  vertical-align: top;
  padding-top: .2em;
}

.comment:before {
  content: "//";
  position: absolute;
  left: -20px;
}

/* CV row */

.cv-row {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  margin: 100px 0;
  font-size: 1.1em;
}

.cv-row .pdf-link {
  color: var(--foreground-color);
  font-weight: 300;
  text-decoration: none;
  flex-shrink: 0;
}

.cv-row .pdf-link:hover {
  font-weight: 500;
}

.cv-row span {
  display: block;
  width: 50%;
  letter-spacing: -.2em;
  padding-bottom: .1em;
  cursor: default;
}

.cv-row span:first-child {
  text-align: right;
  margin-right: 1.15em;
}

.cv-row span:last-child {
  margin-left: 1em;
}

/* Thumbnails */

.thumbs-row {
  width: calc(100% + 5px);
  display: flex;
  flex-direction: row;
  justify-content: left;
  margin: 25px 0 45px -5px;
  flex-wrap: wrap;
}

.thumbs-row img {
  display: block;
  height: 100px;
  align-self: center;
  margin: 0 5px 10px;
}

.thumbs-row img.bordered {
  border: 1px double rgba(0, 0, 0, .25);
}

/* Images */

.full-width-image {
  width: 100%;
}

.images-row {
  display: flex;
  width: 100%;
  flex-direction: row;
  justify-content: left;
}

.images-row figure {
  margin-left: .5em;
  margin-right: .5em;
}

.images-row figure img {
  max-width: 100%;
}
