:root {
  --bg: #fafafa;
  --text: rgba(0, 0, 0, 0.88);
  --muted: #767676;
  --link: rgba(2, 106, 225, 0.88);
  --frame: #eaeaea;
  --brand: rgba(29, 0, 41, 0.88);
  --gutter: 16px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 500 16px/28px "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, p, ul {
  margin: 0;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: var(--link);
  text-decoration: underline;
  text-underline-offset: 2px;
}

a:hover {
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: 2px solid var(--link);
  outline-offset: 2px;
}

.page {
  max-width: calc(648px + 2 * var(--gutter));
  margin: 0 auto;
  padding: 40px var(--gutter) 64px;
}

/* Header ----------------------------------------------------------------- */

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: block;
  width: 44px;
  height: 48px;
  color: var(--brand);
}

.contact {
  display: flex;
  gap: 32px;
  font-weight: 600;
}

.contact .email {
  color: var(--text);
  text-decoration: none;
}

/* Intro ------------------------------------------------------------------ */

.frame {
  background: var(--frame);
  padding: 6px;
  border-radius: 18px;
}

.frame img {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 0 1px rgba(0, 0, 0, 0.12);
  object-fit: cover;
}

.portrait {
  width: 324px;
  margin-top: 64px;
}

.portrait img {
  width: 100%;
  aspect-ratio: 312 / 249;
}

.name {
  margin-top: 36px;
  font-size: 22px;
}

h1 {
  margin-top: 24px;
  font-size: 32px;
  line-height: 40px;
  font-weight: 700;
}

.intro {
  margin-top: 64px;
  color: var(--muted);
}

.intro ul {
  margin: 28px 0 32px;
  padding-left: 21px;
}

/* Sections --------------------------------------------------------------- */

section {
  margin-top: 88px;
}

h2 {
  font-size: 18px;
  font-weight: 600;
}

h3 {
  font-size: 16px;
  font-weight: 600;
}

.lead {
  margin-top: 16px;
  color: var(--muted);
}

.muted {
  color: var(--muted);
  font-weight: 400;
}

/* Portfolio projects */

.projects {
  list-style: none;
  padding: 0;
  margin-top: 40px;
  display: grid;
  gap: 32px;
}

.project {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 24px;
  align-items: start;
}

.project .frame img {
  width: 76px;
  height: 76px;
  padding: 20px 14px;
  object-fit: contain;
}

.project a {
  font-weight: 600;
}

/* Work experience & education */

.timeline {
  list-style: none;
  padding: 0;
  margin-top: 40px;
  display: grid;
  gap: 32px;
}

.timeline li {
  display: grid;
  grid-template-columns: 168px 1fr;
  gap: 24px;
}

.timeline .dates {
  font-size: 14px;
  font-weight: 400;
  color: var(--muted);
}

.more {
  display: inline-block;
  margin: 36px 0 0 192px;
  font-weight: 600;
}

/* Testimonials */

.testimonials {
  list-style: none;
  padding: 0;
  margin-top: 40px;
  display: grid;
  gap: 28px;
}

.testimonial {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 24px;
  align-items: start;
}

.testimonial .frame {
  border-radius: 50%;
}

.testimonial .frame img {
  width: 60px;
  height: 60px;
  border-radius: 50%;
}

.testimonial blockquote {
  margin: 0;
  font-weight: 400;
}

.testimonial figcaption {
  margin-top: 16px;
}

.testimonial figcaption a {
  color: var(--text);
}

.testimonials-extra {
  margin-top: 28px;
}

.testimonials-extra[hidden] {
  display: none;
}

.show-more {
  margin: 28px 0 0 96px;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  font-weight: 600;
  color: var(--link);
  cursor: pointer;
}

/* Footer ----------------------------------------------------------------- */

.site-footer {
  margin-top: 64px;
}

.site-footer a {
  color: var(--text);
}

/* Mobile ----------------------------------------------------------------- */

@media (max-width: 700px) {
  .page {
    padding-top: 40px;
  }

  .site-header .contact {
    display: none;
  }

  .contact-mobile {
    display: flex;
    margin-top: 24px;
  }

  .portrait {
    width: 100%;
    margin-top: 40px;
  }

  h1 {
    font-size: 28px;
    line-height: 36px;
  }

  .intro {
    margin-top: 40px;
  }

  section {
    margin-top: 64px;
  }

  .timeline li {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .more {
    margin-left: 0;
  }

  .testimonial {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .show-more {
    margin-left: 0;
  }
}

@media (min-width: 701px) {
  .contact-mobile {
    display: none;
  }
}
