/* ============================================
   VARIABLES
============================================ */

:root {
  --background: #f5f3ed;
  --background-secondary: #eeece5;

  --text: #242621;
  --muted: #6b6d66;

  --accent: #465748;
  --accent-dark: #334036;

  --line: #d5d3ca;
  --paper: #ffffff;

  --serif: Georgia, "Times New Roman", serif;
  --sans: Arial, Helvetica, sans-serif;

  --max-width: 1080px;
}


/* ============================================
   BASE
============================================ */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;

  background: var(--background);
  color: var(--text);

  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;

  -webkit-font-smoothing: antialiased;
}

.container {
  width: min(calc(100% - 48px), var(--max-width));
  margin: 0 auto;
}

a {
  color: inherit;
}


/* ============================================
   HEADER
============================================ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;

  background: rgba(245, 243, 237, 0.94);
  border-bottom: 1px solid var(--line);

  backdrop-filter: blur(12px);
}

.header-inner {
  min-height: 68px;

  display: flex;
  align-items: center;
  justify-content: space-between;

  gap: 30px;
}

.header-name {
  font-family: var(--serif);
  font-size: 1.05rem;
  text-decoration: none;
}

nav {
  display: flex;
  gap: 28px;
}

nav a {
  color: var(--muted);

  font-size: 0.82rem;
  letter-spacing: 0.02em;

  text-decoration: none;

  transition: color 150ms ease;
}

nav a:hover {
  color: var(--text);
}


/* ============================================
   INTRO
============================================ */

.intro {
  padding: 115px 0 105px;

  border-bottom: 1px solid var(--line);
}

.intro h1 {
  margin: 0;

  font-family: var(--serif);
  font-size: clamp(4rem, 9vw, 7.5rem);
  font-weight: 400;

  letter-spacing: -0.055em;
  line-height: 0.95;
}

.positions {
  margin-top: 32px;
}

.positions p {
  margin: 5px 0;

  color: var(--text);

  font-size: 0.95rem;
}

.positions p span {
  margin-left: 7px;

  color: var(--muted);
}

.positions p span::before {
  content: "·";
  margin-right: 7px;
}

.affiliation {
  margin: 22px 0 0;

  color: var(--muted);

  font-family: var(--serif);
  font-size: 1rem;
}


/* ============================================
   PROFILE LINKS
============================================ */

.profile-links {
  display: flex;
  flex-wrap: wrap;

  gap: 10px 28px;

  margin-top: 38px;
}

.profile-links a {
  display: inline-flex;
  align-items: center;

  gap: 6px;

  color: var(--accent);

  font-size: 0.82rem;
  font-weight: 600;

  text-decoration: none;

  border-bottom: 1px solid transparent;

  transition:
    color 150ms ease,
    border-color 150ms ease;
}

.profile-links a:hover {
  color: var(--accent-dark);
  border-color: var(--accent-dark);
}

.profile-links span {
  font-size: 0.75rem;
}


/* ============================================
   SECTIONS
============================================ */

.section {
  padding: 95px 0;

  border-bottom: 1px solid var(--line);

  scroll-margin-top: 68px;
}

.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;

  gap: 30px;

  margin-bottom: 40px;
}

.section-header h2,
.contact h2 {
  margin: 0;

  font-family: var(--serif);
  font-size: 2rem;
  font-weight: 400;

  letter-spacing: -0.02em;
}


/* ============================================
   CV
============================================ */

.document-links {
  display: flex;
  gap: 20px;
}

.document-links a {
  color: var(--accent);

  font-size: 0.8rem;
  font-weight: 600;

  text-decoration: none;

  border-bottom: 1px solid transparent;
}

.document-links a:hover {
  border-color: var(--accent);
}

.pdf-frame {
  width: 100%;
  height: 900px;

  overflow: hidden;

  background: var(--paper);

  border: 1px solid var(--line);
  border-radius: 2px;

  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.025),
    0 12px 40px rgba(0, 0, 0, 0.035);
}

.pdf-frame iframe {
  display: block;

  width: 100%;
  height: 100%;

  border: 0;
}


/* ============================================
   PUBLICATIONS
============================================ */

.publication-list {
  border-top: 1px solid var(--line);
}

.publication {
  display: grid;

  grid-template-columns: 100px minmax(0, 1fr);

  gap: 35px;

  padding: 36px 0;

  border-bottom: 1px solid var(--line);
}

.publication-year {
  padding-top: 4px;

  color: var(--accent);

  font-family: var(--serif);
  font-size: 1rem;
}

.publication-content {
  max-width: 800px;
}

.publication-title {
  display: inline;

  font-family: var(--serif);
  font-size: 1.35rem;
  line-height: 1.4;

  text-decoration: none;

  transition: color 150ms ease;
}

.publication-title:hover {
  color: var(--accent);
}

.publication-authors {
  margin: 13px 0 0;

  color: var(--muted);

  font-size: 0.87rem;
}

.publication-source {
  margin: 3px 0 0;

  color: var(--muted);

  font-size: 0.87rem;
}

.doi {
  display: inline-block;

  margin-top: 13px;

  color: var(--accent);

  font-size: 0.74rem;
  font-weight: 600;

  text-decoration: none;

  border-bottom: 1px solid transparent;
}

.doi:hover {
  border-color: var(--accent);
}


/* ============================================
   CONTACT
============================================ */

.contact {
  padding: 80px 0;

  background: var(--background-secondary);

  scroll-margin-top: 68px;
}

.contact-inner {
  display: flex;
  align-items: baseline;
  justify-content: space-between;

  gap: 40px;
}

.contact a {
  color: var(--accent);

  font-size: 0.9rem;

  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}


/* ============================================
   FOOTER
============================================ */

footer {
  padding: 25px 0;

  background: var(--accent-dark);
  color: #d9ddd8;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

footer p {
  margin: 0;

  font-size: 0.72rem;
}

footer a {
  color: inherit;

  font-size: 0.9rem;

  text-decoration: none;
}


/* ============================================
   MOBILE
============================================ */

@media (max-width: 700px) {

  .container {
    width: min(calc(100% - 32px), var(--max-width));
  }

  .header-inner {
    min-height: auto;

    flex-direction: column;
    align-items: flex-start;

    gap: 8px;

    padding: 15px 0;
  }

  nav {
    gap: 20px;
  }

  .intro {
    padding: 80px 0 70px;
  }

  .intro h1 {
    font-size: clamp(3.5rem, 18vw, 5rem);
  }

  .position {
    margin-top: 22px;
  }

  .profile-links {
    margin-top: 30px;
  }

  .section {
    padding: 65px 0;
  }

  .section-header {
    align-items: flex-start;
    flex-direction: column;

    gap: 12px;

    margin-bottom: 28px;
  }

  .pdf-frame {
    height: 650px;
  }

  .publication {
    grid-template-columns: 1fr;

    gap: 8px;

    padding: 30px 0;
  }

  .publication-year {
    padding: 0;
  }

  .publication-title {
    font-size: 1.2rem;
  }

  .contact-inner {
    flex-direction: column;

    gap: 18px;
  }

}
