:root {
  color-scheme: light;
  --text: #5f5f5f;
  --heading: #1f1f1f;
  --muted: #555;
  --link: #363636;
  --line: #e7e4df;
  --background: #fbfaf8;
  --surface: #fff;
  --surface-soft: #f4f2ee;
  --focus: #111;
  --measure: 720px;
  --wide: 920px;
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 62.5%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--background);
  color: var(--text);
  font: 16px/1 -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
}

a {
  color: var(--link);
  text-decoration: underline;
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}

a:focus-visible,
button:focus-visible,
audio:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 4px;
}

img,
pre,
iframe {
  max-width: 100%;
}

img,
pre {
  border-radius: 4px;
}

p {
  margin: 0 0 20px;
  color: var(--text);
  font-weight: 300;
  letter-spacing: 0.2px;
  line-height: 1.72;
}

h1,
h2,
h3,
h4 {
  color: var(--heading);
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
  text-rendering: optimizeLegibility;
}

h1 {
  margin: 0.67em 0;
  font-size: 3rem;
  font-weight: 700;
  letter-spacing: 0;
}

h2 {
  font-size: 2.2rem;
}

h3 {
  font-size: 2rem;
}

h4 {
  font-size: 1.6rem;
}

strong {
  color: #000;
  font-weight: 400;
}

ul,
ol {
  margin-bottom: 20px;
}

li {
  color: var(--text);
  font-weight: 300;
  line-height: 2.4rem;
}

blockquote {
  margin: 0 0 20px 0;
  padding-left: 15px;
  border-left: 3px solid var(--line);
}

hr {
  width: 100%;
  height: 1px;
  margin: 40px auto;
  border: 0;
  background: var(--line);
}

code,
tt {
  padding: 1px 3px;
  border-radius: 2px;
  background: var(--surface-soft);
  font: 12px/20px Consolas, "Liberation Mono", Menlo, Courier, monospace;
}

pre {
  width: 100%;
  margin: 0 0 1.75em;
  padding: 10px;
  overflow: auto;
  border: 1px solid var(--line);
  background: var(--surface);
  font: 1.2rem/2rem Consolas, "Liberation Mono", Menlo, Courier, monospace;
}

.wrapper {
  width: 96%;
  max-width: var(--wide);
  min-height: 100vh;
  margin: 0 auto;
  padding: 1px 0;
}

.page,
.home,
.blog,
.projects,
.tags,
.cv {
  position: relative;
  margin-top: 72px;
}

.home,
.blog,
.projects,
.tags {
  margin-top: 112px;
}

.page {
  max-width: var(--measure);
  margin-right: auto;
  margin-left: auto;
}

.cv {
  max-width: var(--wide);
}

.page > h1 {
  margin-bottom: 5rem;
  text-align: center;
}

.page > h1::after,
.cv-section > h2::after {
  content: "";
  display: block;
  width: 30px;
  height: 1px;
  margin: 22px auto 0;
  background: var(--line);
}

.site-header {
  position: relative;
  z-index: 2;
  display: block;
  margin: 0 auto;
  text-align: center;
}

.site-header__link {
  display: inline-block;
}

.site-header__photo {
  width: 125px;
  height: 125px;
  margin-bottom: 25px;
  border: 1px solid rgba(0, 0, 0, 0.04);
  border-radius: 50%;
  object-fit: cover;
  opacity: 1;
  transition: box-shadow 0.2s, opacity 0.2s;
}

.site-header__photo:hover {
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.18), 0 0 12px rgba(0, 0, 0, 0.15);
  opacity: 0.82;
}

.site-header__title {
  margin: 0 0 13px;
  font-size: 4.2rem;
  letter-spacing: 0;
}

.site-header__description {
  width: 70%;
  margin: 0 auto 30px;
  color: var(--muted);
  font-size: 1.85rem;
  font-style: normal;
  font-weight: 300;
}

.animated {
  animation: fade-in-down 0.6s 0.15s both;
}

@keyframes fade-in-down {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.nav,
.nav-home {
  margin: 0;
  text-align: center;
}

.nav {
  position: static;
  margin: 0 0 54px;
}

.nav-home {
  margin-top: 40px;
  text-align: center;
}

.site-header + .nav {
  margin-top: 38px;
  margin-bottom: 4px;
}

.nav__list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2px 10px;
  margin: 0;
  padding: 0 13px;
  list-style: none;
}

.nav-home .nav__list {
  padding: 0;
}

.nav__item {
  display: block;
}

.nav__link {
  display: inline-block;
  padding: 9px 10px;
  color: var(--link);
  font-size: 1.4rem;
  font-weight: 300;
  text-decoration: none;
  transition: color 0.2s ease-in-out, transform 0.2s ease-in-out;
}

.nav-home .nav__link {
  width: 70px;
  margin: 0;
  padding: 7px 15px;
  border-radius: 4%;
  font-size: 2rem;
  transition: color 0.25s ease-in-out;
}

.nav__link:hover {
  color: var(--text);
  transform: translateY(-1px);
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px;
  margin-top: 20px;
}

.social-links__link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 35px;
  height: 35px;
  color: var(--muted);
  text-decoration: none;
}

.social-links__icon {
  display: block;
  width: 21px;
  height: 21px;
  fill: currentColor;
  transition: color 0.2s ease-in-out;
}

.social-links__link:hover {
  color: var(--link);
  transform: translateY(-1px);
}

.social-links__link::before {
  content: attr(aria-label);
  position: absolute;
  bottom: -34px;
  left: -6px;
  z-index: 9;
  display: none;
  height: 22px;
  padding: 3px 10px;
  border-radius: 2px;
  background: var(--heading);
  color: #fff;
  font-size: 13px;
  line-height: 22px;
  white-space: nowrap;
}

.social-links__link::after {
  content: "";
  position: absolute;
  top: 35px;
  left: 13px;
  display: none;
  width: 0;
  height: 0;
  border-right: 5px solid transparent;
  border-bottom: 6px solid var(--heading);
  border-left: 5px solid transparent;
}

.social-links__link:hover::before,
.social-links__link:hover::after {
  display: inline-block;
}

.list {
  position: relative;
  margin-top: 34px;
  padding-top: 34px;
  border-top: 1px solid var(--line);
}

.list::before {
  content: " ";
  position: absolute;
  top: -5px;
  left: 50%;
  z-index: 1;
  display: block;
  width: 7px;
  height: 7px;
  margin-left: -5px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: #fff;
  box-shadow: #fff 0 0 0 5px;
}

.list__item {
  display: block;
  width: min(95%, var(--measure));
  margin: 0 auto;
  border-bottom: 1px solid color-mix(in srgb, var(--line) 72%, transparent);
}

.list__item:last-child {
  border-bottom: 0;
}

.list__link {
  display: block;
  width: 100%;
  min-height: 64px;
  padding: 22px 0;
  text-decoration: none;
}

.list__date {
  position: relative;
  top: 2px;
  float: right;
  width: 25%;
  margin: 0;
  color: var(--muted);
  font-weight: 300;
  text-align: right;
  transition: color 0.2s ease-in-out;
}

.list__title {
  width: 75%;
  margin: 0;
  color: var(--heading);
  font-weight: 500;
  line-height: 1.35;
  transition: color 0.2s ease-in-out;
}

.list__link:hover .list__title,
.list__link:hover .list__date {
  color: var(--link);
}

.text-center {
  text-align: center;
}

.post article,
.about,
.cv {
  max-width: var(--measure);
}

.cv {
  max-width: var(--wide);
}

.post__title {
  margin-bottom: 1rem;
  text-align: center;
}

.post__meta {
  display: block;
  margin-bottom: 2rem;
  color: var(--muted);
  font-size: 1.4rem;
  font-weight: 300;
  text-align: center;
}

.post__tags {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 4rem;
}

.post__tag {
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 3px;
  color: var(--muted);
  font-size: 1.2rem;
  text-decoration: none;
}

.post img {
  display: block;
  margin: 0 auto 28px;
}

.about img {
  display: block;
  width: min(50%, 280px);
  margin: 0 auto 34px;
  border-radius: 50%;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.08);
}

.cv-hero {
  display: grid;
  grid-template-columns: 136px minmax(0, 1fr);
  gap: 32px;
  align-items: center;
  margin-bottom: 60px;
  padding-bottom: 42px;
  border-bottom: 1px solid var(--line);
}

.cv-hero img {
  width: 132px;
  height: 132px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.08);
}

.cv-hero h1 {
  margin: 0 0 10px;
  font-size: 4.4rem;
}

.cv-hero p {
  max-width: 620px;
  margin-bottom: 16px;
  color: var(--muted);
  font-size: 1.9rem;
  line-height: 1.5;
}

.cv-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  font-size: 1.4rem;
  font-weight: 300;
}

.cv-section {
  max-width: var(--measure);
  margin: 0 auto 64px;
}

.cv-section--timeline {
  max-width: var(--wide);
}

.cv-section > h2 {
  margin: 0 0 32px;
  text-align: center;
}

.cv-timeline {
  display: grid;
  gap: 36px;
}

.cv-item {
  display: grid;
  grid-template-columns: minmax(190px, 0.34fr) minmax(0, 1fr);
  gap: 34px;
  padding-bottom: 36px;
  border-bottom: 1px solid var(--line);
}

.cv-item:last-child {
  border-bottom: 0;
}

.cv-item__details h3 {
  margin: 0 0 8px;
  font-size: 1.9rem;
  line-height: 1.3;
}

.cv-item__details a {
  display: inline-block;
  margin-bottom: 14px;
  overflow-wrap: anywhere;
  font-size: 1.35rem;
}

.cv-item__details p {
  margin-bottom: 8px;
  font-size: 1.42rem;
  line-height: 1.45;
}

.cv-item__quote {
  color: var(--heading);
  font-style: italic;
}

.cv-item ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2px 24px;
  padding-left: 18px;
}

.footer {
  margin: 90px 0 34px;
  color: var(--muted);
  font-size: 1.3rem;
  font-weight: 300;
  text-align: center;
}

.footer a {
  display: inline-flex;
  vertical-align: middle;
}

.footer svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
}

@media only screen and (max-width: 780px) {
  .nav {
    margin: 0 0 42px;
    text-align: center;
  }

  .site-header + .nav {
    margin-top: 32px;
    margin-bottom: 0;
  }

  .page {
    margin-top: 48px;
  }

  .cv-hero {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .cv-contact {
    justify-content: center;
  }

  .cv-item {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .cv-item__details {
    padding-bottom: 8px;
  }
}

@media only screen and (max-width: 400px) {
  .wrapper {
    width: 88%;
  }

  p {
    letter-spacing: 0.2px;
  }

  .site-header__description {
    width: 100%;
  }

  .nav-home .nav__link {
    width: auto;
    min-width: 60px;
    font-size: 1.8rem;
  }

  .list__date {
    float: none;
    width: 100%;
    margin-bottom: 8px;
    text-align: left;
  }

  .list__title {
    width: 100%;
  }

  .about img {
    width: 74%;
  }

  .cv-hero h1 {
    font-size: 3.4rem;
  }

  .cv-item ul {
    grid-template-columns: 1fr;
  }
}
