

/* ---------- Base / reset ---------- */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: Arial, sans-serif;
  background: #fff;
  color: #333;
  font-size: 16px;
  line-height: 1.6;
  margin: 0;
  padding: 0;
}

/* Remove nav if still defined somewhere */
.navbar { display: none; }

/* ---------- Header (Name) ---------- */
.header {
  text-align: center;
  font-size: 1.3rem;
  font-weight: bold;
  margin-top: 60px;       /* slightly lower than before (was 40px) */
  margin-bottom: 8px;     /* tighter space before body text */
  color: #000;
}


/* ---------- Layout ---------- */
.container {
  display: flex;
  justify-content: center;
  max-width: 1100px;
  margin: 40px auto 0;
  padding: 20px;
}

.content {
  display: flex;
  flex-direction: row;       /* image left, text right on desktop */
  align-items: flex-start;
  justify-content: center;
  gap: 30px;
}

/* ---------- Profile (left column) ---------- */
.profile {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 0 0 auto;
}

.profile img {
  width: 190px;
  height: 190px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 12px;
}
/* --- CV | Email line --- */
.buttons {
  text-align: left;
  font-size: 0.9rem;
  color: #444;
  margin-top: 6px;
}

/* “CV” link — bold + blue */
.buttons strong a {
  font-weight: bold;
  color: #008cba;        /* blue like your other links */
  text-decoration: none;
}

.buttons strong a:hover {
  text-decoration: underline;
}

/* “Email:” label — bold black */
.buttons strong {
  font-weight: bold;
  color: #000;
}

/* email address — normal blue, not bold */
.buttons a {
  color: #008cba;
  text-decoration: none;
  font-weight: normal;
  margin: 0 3px;
}

.buttons a:hover {
  text-decoration: underline;
}

/* ---------- Description (right column) ---------- */
.description {
  text-align: left;
  max-width: 640px;
  color: #444;
  margin-left: 20px;
  margin-bottom: 30px;     /* adds more space before Working Papers */
}
.description p:first-child { margin-top: 0; }
.description p { margin-bottom: 25px; }


/* ---------- Papers ---------- */

/* ---------- Papers ---------- */
.papers { 
  margin-top: 60px;
}
.papers h2 {
  font-size: 1.1rem;
  font-weight: bold;
  color: #000;
  margin-bottom: 10px;
}

.paper { margin-bottom: 15px; color: #000; }

.paper h3 {
  font-size: 1rem;
  font-weight: 600;
  color: #000;
  display: inline;
  margin-bottom: 2px;
}

.plink a {
  color: #008cba;
  text-decoration: none;
  margin-left: 4px;
  font-size: 0.95rem;
}
.plink a:hover { text-decoration: underline; }

/* “Job Market Paper” on separate line */
.meta-line {
  margin: 0 0 3px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: baseline;
}
.jlabel {
  font-style: italic;
  font-size: 0.95rem;
  color: #555;
}

/* ---------- Indents for sublines ---------- */
:root { --subindent: 4px; } /* smaller indent for cleaner alignment */

.presented {
  font-size: 0.85rem;
  color: #555;
  margin-bottom: 2px;
}

.coauthors {
  font-size: 0.92rem;
  color: #000;
  margin-bottom: 2px;
}
.coauthors a {
  font-style: italic;
  color: #008cba;
  text-decoration: none;
  margin-bottom: 2px;
}
.coauthors a:hover { text-decoration: underline; }

/* ---------- Abstract toggle ---------- */
.abstract {
  margin-left: var(--subindent);
  margin-top: 0;
}

.abstract summary {
  cursor: pointer;
  color: #008cba;
  font-weight: normal;
  margin-top: 0;
  margin-bottom: 0;
  list-style: none;
  position: relative;
  font-size: 0.92rem;
  padding-left: 16px;
}

.abstract summary::before {
  content: "▶";
  position: absolute;
  left: 0;
  top: 0;
  color: #008cba;
  font-weight: normal;
  transition: transform .2s ease;
}
details[open] summary::before { transform: rotate(90deg); }

.abstract div {
  margin-top: 3px;
  color: #444;
  font-size: 0.95rem;
  margin-left: 16px; /* align under arrow text */
}

/* ---- Fix stubborn spacing above Abstract ---- */
details.abstract {
  margin-top: 0 !important;      /* removes built-in details margin */
  padding-top: 0 !important;
}

.abstract summary {
  margin-top: 0 !important;      /* extra assurance */
  margin-bottom: 0 !important;
  padding-top: 0 !important;
}

.presented {
  margin-bottom: 1px !important; /* super tight below “Presented at” */
}

.coauthors {
  margin-bottom: 1px !important;
}

/* Prevent page shift when <details> opens (reserve scrollbar space) */
html {
  scrollbar-gutter: stable;   /* modern fix */
  overflow-y: scroll;         /* fallback for older browsers */
}

/* Also avoid any focus jiggle on the summary */
.abstract summary {
  outline: none;
}
.abstract summary:focus {
  outline: none;
}

/* Special color for [Slides] links */
.slides-link a {
  color: #c58f00;           /* gold / amber */
  text-decoration: none;
}

.slides-link a:hover {
  text-decoration: underline;
  color: #a67500;            /* darker gold on hover */
  font-size: 0.95rem;
}

/* Make [Latest version] appear on a new line, no indent */
.latest-link {
  display: block;        /* puts it on its own line */
  margin-left: 0;        /* removes the indent */
}

.latest-link a {
  color: #008cba;
  text-decoration: none;
  font-size: 0.95rem;    /* slightly smaller than title */
  font-weight: normal;
}

.latest-link a:hover {
  text-decoration: underline;
}
/* kill the inherited plink margin on [Latest version] */
.latest-link { display:block; margin-left:0; }
.latest-link a { margin-left:0 !important; padding-left:0; }

/* ---------- Mobile ---------- */
@media (max-width: 768px) {
  .container {
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-top: 20px;
  }
  .content {
    flex-direction: column;
    align-items: center;
    gap: 15px;
  }
  .profile img {
    width: 130px;
    height: 130px;
  }
  .description {
    margin-left: 0;
    text-align: left;
    max-width: 92%;
  }
  .papers { text-align: left; }
}
