/* Herilalaina Rakotoarison — personal site. Black type on white; the portrait is the only colour. */

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  background: #ffffff;
  color: #111111;
  font-family: "Source Serif 4", Georgia, "Times New Roman", serif;
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -webkit-text-size-adjust: 100%;
}

a {
  color: #111111;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a:hover, a:focus { color: #000000; text-decoration-thickness: 2px; }

.page {
  max-width: 848px; /* 720px of content plus 64px padding each side */
  margin: 0 auto;
  padding: 96px 64px;
  display: flex;
  flex-direction: column;
  gap: 56px;
}

/* Header: portrait beside name and intro */
.intro {
  display: flex;
  flex-direction: row;
  gap: 40px;
  align-items: flex-start;
}
.intro img {
  width: 107px;
  height: 160px;
  object-fit: cover;
  flex-shrink: 0;
  display: block;
}
.intro-text {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-top: 6px;
}
.intro h1 {
  margin: 0;
  font-size: 34px;
  line-height: 1.15;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.intro p { margin: 0; }
.intro .role { font-size: 19px; line-height: 1.5; }

/* Sections */
section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
section h2 {
  margin: 0;
  font-size: 14px;
  line-height: 1.4;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.rule { height: 1px; background: #111111; }

.about { margin: 0; line-height: 1.6; }

/* Publications: three lines per paper */
.publications {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.publications li {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.publications .title { line-height: 1.4; }
.publications .meta {
  font-size: 15px;
  line-height: 1.5;
  color: #555555;
}
section .more { margin: 8px 0 0 0; }

/* 404 */
section h1 { margin: 0; font-size: 34px; line-height: 1.15; font-weight: 600; }
section p { margin: 0; }

/* Phone */
@media (max-width: 600px) {
  .page { padding: 48px 24px 64px; gap: 44px; }
  .intro { flex-direction: column; gap: 24px; }
  .intro-text { padding-top: 0; }
  .intro h1 { font-size: 30px; }
}
