/* Daniel de Oliveira — personal page
   Visual language adapted from uffescience.ic.uff.br (UFFeScience Research Group). */
@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:wght@400;450;500;600;700&family=IBM+Plex+Mono:wght@400;500&display=swap');

:root {
  --ink: #102b47;
  --blue: #166fa8;
  --muted: #637587;
  --line: #dce4ec;
  --soft: #f3f7fa;
  --mono: 'IBM Plex Mono', monospace;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: #fff;
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 14px;
}
a { color: inherit; text-decoration: none; }
a:hover { color: var(--blue); }
a, button, summary { outline-offset: 4px; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 2px solid var(--blue); }
button { font: inherit; cursor: pointer; }
h1, h2, h3, h4, p { margin-top: 0; }
img { max-width: 100%; }
::selection { background: #cfe6f6; }
.icon { width: 1em; height: 1em; flex-shrink: 0; vertical-align: -0.12em; }

/* ---------- Header ---------- */
.site-header, main, footer { max-width: 1280px; margin: auto; }
.site-header {
  display: flex;
  align-items: center;
  gap: 32px;
  min-height: 106px;
  padding: 0 40px;
  border-bottom: 1px solid var(--line);
}
.logo-link { display: flex; align-items: center; gap: 13px; margin-right: auto; flex-shrink: 0; }
.logo-link img { width: 72px; height: 72px; object-fit: contain; }
.logo-link > span {
  font-size: 15px;
  font-weight: 600;
  padding-left: 16px;
  border-left: 1px solid var(--line);
  line-height: 1.6;
}
.logo-link small { display: block; font-size: 11px; font-weight: 400; color: var(--muted); }
nav { display: flex; gap: 22px; font-size: 13px; }
nav a { white-space: nowrap; padding: 6px 0; border-bottom: 1px solid transparent; }
nav a[aria-current='page'] { color: var(--blue); border-bottom-color: var(--blue); }
.header-group {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-left: 24px;
  border-left: 1px solid var(--line);
  font-size: 12px;
  white-space: nowrap;
}

/* ---------- Typography ---------- */
.kicker {
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 1.1px;
  display: flex;
  gap: 8px;
  align-items: center;
  color: #617488;
  text-transform: uppercase;
}
.kicker > span, .status-dot {
  height: 6px;
  width: 6px;
  display: inline-block;
  flex-shrink: 0;
  background: #1779b6;
  border-radius: 50%;
}
h1 {
  font-weight: 500;
  font-size: 46px;
  line-height: 1.17;
  letter-spacing: -1.7px;
  margin: 23px 0;
}
h1 > span { color: #487494; }
h2 {
  font-size: 29px;
  letter-spacing: -0.8px;
  font-weight: 500;
  line-height: 1.25;
  margin: 13px 0;
}

/* ---------- Hero / page intro ---------- */
.intro-copy > p { color: var(--muted); font-size: 15px; line-height: 1.85; max-width: 560px; }
.intro-copy > p a, .prose a { color: var(--blue); }
.intro-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 27px; margin-top: 30px; }
.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  background: var(--ink);
  color: white;
  padding: 14px 19px;
  font-size: 12px;
  border-radius: 3px;
}
.primary-button:hover { background: var(--blue); color: white; }
.quiet-link { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 500; }
.intro-location { font-size: 11px; color: #8593a0; margin-top: 35px; }

.campus-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: 45px;
  align-items: stretch;
  padding: 45px 40px 50px;
}
.campus-hero .intro-copy { display: flex; flex-direction: column; justify-content: center; padding: 20px 0; }
.campus-hero h1 { font-size: 43px; }
.intro-campus { min-width: 0; }
.intro-campus figure { position: relative; height: 100%; margin: 0; }
.intro-campus figure img {
  width: 100%;
  height: 100%;
  min-height: 430px;
  object-fit: cover;
  border-radius: 3px;
  display: block;
}
.intro-campus figcaption {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 70px 19px 17px;
  background: linear-gradient(transparent, #061a2fe0);
  color: #fff;
  margin: 0;
  border-radius: 0 0 3px 3px;
}
.intro-campus figcaption > span { display: block; font-size: 12px; }
.intro-campus figcaption small { display: block; font-size: 9px; color: #cedae6; margin-top: 5px; }

.page-intro { padding: 56px 40px 44px; }
.page-intro h1 { margin: 20px 0 18px; }
.page-intro p { color: var(--muted); font-size: 15px; line-height: 1.85; max-width: 760px; margin: 0; }
.page-intro p + p { margin-top: 12px; }
.page-intro p a { color: var(--blue); }

/* ---------- Sections ---------- */
.section { padding: 48px 40px 56px; border-top: 1px solid var(--line); }
.section.tinted { background: #f8fafc; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.source-label { display: flex; align-items: center; gap: 8px; font-size: 10px; color: #6a7f92; }
.section-description { font-size: 12px; color: var(--muted); line-height: 1.8; margin-bottom: 24px; max-width: 760px; }
.section-description a { color: var(--blue); }
.prose p { font-size: 15px; line-height: 1.85; color: #405f78; max-width: 760px; }
.directory-note { font-size: 11px; color: #8a9dab; margin: 20px 0 0; line-height: 1.7; }
.directory-note a { color: var(--blue); }
.text-link { display: inline-flex; align-items: center; gap: 8px; color: #7192ab; font-size: 11px; }

/* ---------- About (home) ---------- */
.people-lead { display: flex; gap: 36px; align-items: flex-start; padding: 24px 0 0; }
.people-lead > img {
  width: 144px;
  height: 164px;
  object-fit: cover;
  border-radius: 4px;
  flex-shrink: 0;
}
.people-lead p { font-size: 15px; line-height: 1.8; color: #506782; margin: 0 0 16px; max-width: 760px; }
.people-lead p a { color: var(--blue); }
.profile-links { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 0; padding: 0; list-style: none; }
.profile-links a {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 7px 12px 7px 8px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: #fff;
  font-size: 12px;
}
.profile-links a:hover { border-color: #b9cfdf; background: #f5f9fc; }
.profile-links img { width: 20px; height: 20px; object-fit: contain; border-radius: 2px; }

.banner-card { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 40px; align-items: center; margin-top: 18px; }
.banner-card img { width: 100%; display: block; border-radius: 4px; border: 1px solid var(--line); }
.banner-card p { font-size: 13px; color: var(--muted); line-height: 1.8; }
.quote {
  margin: 0;
  padding: 0 0 0 18px;
  border-left: 2px solid #b8d2e4;
  font-size: 15px;
  line-height: 1.8;
  color: #405f78;
}
.quote cite { display: block; margin-top: 8px; font-size: 11px; font-style: normal; color: #8593a0; }

.catalog-search { display: flex; max-width: 560px; margin-top: 18px; }
.catalog-search input[type='text'] {
  flex: 1;
  min-width: 0;
  border: 1px solid #cbd8e2;
  border-right: 0;
  border-radius: 3px 0 0 3px;
  padding: 12px 14px;
  font: inherit;
  color: #15344e;
}
.catalog-search input[type='text']:focus-visible { outline: 2px solid #167ab4; outline-offset: 2px; }
.catalog-search button {
  border: 0;
  background: var(--ink);
  color: #fff;
  padding: 0 20px;
  font-size: 12px;
  border-radius: 0 3px 3px 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.catalog-search button:hover { background: var(--blue); }

/* ---------- Cards (publications, news, areas, courses) ---------- */
.publication-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr));
  gap: 22px;
  margin-top: 21px;
}
.publication-grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.publication-preview {
  min-width: 0;
  background: #fff;
  border: 1px solid #dee7ed;
  border-radius: 5px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.publication-cover { width: 100%; height: 190px; object-fit: cover; display: block; background: #f0f5f8; }
.publication-preview-content { padding: 20px; display: flex; flex-direction: column; flex: 1; }
.publication-preview .kicker { margin-bottom: 12px; }
.publication-preview h3 {
  font-size: 17px;
  line-height: 1.45;
  letter-spacing: -0.35px;
  font-weight: 500;
  margin: 0 0 12px;
  overflow-wrap: anywhere;
}
.publication-preview h3 a:hover { color: var(--blue); }
.publication-preview-content > p { font-size: 12px; line-height: 1.8; color: #748c9f; margin: 0 0 14px; }
.publication-preview-content > p b { color: var(--ink); font-weight: 500; }
.publication-read {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 11px;
  color: #337fac;
  margin-top: auto;
  border-top: 1px solid #edf2f6;
  padding-top: 13px;
}
.publication-read.disabled { color: #a0afba; }
.avatar-stack { display: flex; align-items: center; margin: 2px 0 16px 6px; flex-wrap: wrap; row-gap: 4px; }
.avatar-stack img {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #fff;
  margin-left: -6px;
  background: #edf3f7;
  transition: transform 0.15s;
}
.avatar-stack img:hover { transform: translateY(-3px); position: relative; z-index: 1; }

/* Expandable text (news, project descriptions) */
.expandable { position: relative; }
.expandable-body {
  font-size: 12px;
  line-height: 1.8;
  color: #5e7a8f;
  max-height: 7.2em;
  overflow: hidden;
}
.expandable-body p { margin: 0 0 10px; }
.expandable-body strong, .expandable-body b { color: var(--ink); font-weight: 500; }
.expandable-body a { color: var(--blue); }
.expandable.collapsed .expandable-body {
  -webkit-mask-image: linear-gradient(#000 55%, transparent);
  mask-image: linear-gradient(#000 55%, transparent);
}
.expandable.open .expandable-body { max-height: none; }
.expand-toggle {
  background: none;
  border: 0;
  padding: 8px 0 14px;
  color: #5887a7;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
}
.expand-toggle:hover { color: var(--blue); }
.expandable.open .expand-toggle .icon { transform: rotate(180deg); }
.expandable:not(.collapsed):not(.open) .expand-toggle { display: none; }

/* ---------- Lists with year column (papers, awards) ---------- */
.papers-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.paper-entry {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 12px;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}
.paper-year { font-family: var(--mono); font-size: 12px; color: var(--muted); padding-top: 3px; }
.paper-entry h3 { font-size: 16px; font-weight: 500; line-height: 1.45; margin: 0; overflow-wrap: anywhere; }
.paper-authors, .paper-venue { font-size: 12px; color: var(--muted); line-height: 1.7; margin: 6px 0 0; }
.paper-venue { font-style: italic; }
.paper-kind {
  display: inline-block;
  font-style: normal;
  font-size: 10px;
  color: var(--blue);
  background: #edf4f9;
  border-radius: 999px;
  padding: 1px 8px;
  margin-right: 8px;
}
.year-filter { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 22px; }
.year-filter button {
  min-width: 52px;
  height: 32px;
  padding: 0 12px;
  font-size: 12px;
  color: var(--blue);
  background: #f5f8fb;
  border: 1px solid var(--line);
  border-radius: 3px;
}
.year-filter button:hover { background: #edf4f9; }
.year-filter button.active { color: #fff; background: var(--ink); border-color: var(--ink); }

/* ---------- People ---------- */
.people-group { padding: 28px 0; border-top: 1px solid #e0e7ee; }
.people-group:first-of-type { border-top: 0; }
.people-group > h3, .people-group > summary { font-size: 20px; font-weight: 500; margin: 0 0 24px; letter-spacing: -0.3px; }
.people-group > summary { cursor: pointer; list-style: none; display: flex; align-items: center; gap: 10px; }
.people-group > summary::-webkit-details-marker { display: none; }
.people-group > summary .icon { color: #5887a7; transition: transform 0.15s; }
.people-group:not([open]) > summary { margin-bottom: 0; }
.people-group:not([open]) > summary .icon { transform: rotate(-90deg); }
.people-count { font-family: var(--mono); font-size: 11px; color: #74899d; font-weight: 400; letter-spacing: 0; }
.people-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 26px 22px; }
.person-card { display: flex; gap: 13px; align-items: flex-start; min-width: 0; }
.person-card > img {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: #eaf0f5;
}
.person-card > div { min-width: 0; padding-top: 4px; }
.person-card h4 { font-size: 14px; font-weight: 600; line-height: 1.45; margin: 0 0 3px; }
.person-card h4 a:hover { color: var(--blue); }
.person-card small { display: block; font-size: 11px; color: var(--muted); line-height: 1.55; }
.person-card .person-tag {
  display: inline-block;
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.6px;
  color: #3d83b0;
  margin-top: 5px;
}
.person-card .person-work {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 5px;
  color: #547896;
  font-size: 11px;
  line-height: 1.55;
}
.person-card .person-work:hover { color: var(--blue); }
.section-block + .section-block { margin-top: 30px; }

/* ---------- Projects ---------- */
.project-directory { margin-top: 25px; border-top: 1px solid var(--line); }
.project-entry { padding: 32px 0; border-bottom: 1px solid var(--line); }
.project-entry-header { display: flex; justify-content: space-between; gap: 40px; align-items: flex-start; }
.project-entry-info { flex: 1; min-width: 0; }
.project-entry h3 { font-size: 21px; font-weight: 500; letter-spacing: -0.4px; line-height: 1.35; margin: 0; }
.project-alt-title { font-size: 12px; color: #8a9daa; margin: 6px 0 0; line-height: 1.6; }
.project-meta { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 16px 0 18px; }
.project-meta div { font-size: 11px; color: var(--muted); }
.project-meta span { display: block; font-family: var(--mono); font-size: 9px; letter-spacing: 0.8px; color: #8a9daa; text-transform: uppercase; margin-bottom: 2px; }
.project-meta .active { color: #2c7a54; }
.project-side { width: 220px; flex-shrink: 0; text-align: right; }
.project-side > span { font-size: 9px; color: #8a9daa; display: block; margin-bottom: 10px; font-family: var(--mono); letter-spacing: 0.8px; }
.project-side .avatar-stack { justify-content: flex-end; margin: 0 0 22px; }
.project-side .avatar-stack img { width: 34px; height: 34px; }
.project-side .funder { height: 38px; width: auto; max-width: 140px; object-fit: contain; }

/* ---------- Book ---------- */
.book-layout { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 50px; align-items: start; }
.book-layout img { width: 100%; border-radius: 4px; border: 1px solid var(--line); display: block; }
.book-layout h3 { font-size: 24px; font-weight: 500; letter-spacing: -0.5px; line-height: 1.3; margin: 0 0 8px; }
.book-layout h3 a:hover { color: var(--blue); }
.book-authors { font-size: 13px; color: var(--muted); margin: 0 0 22px; }
.book-layout p { font-size: 14px; line-height: 1.85; color: #405f78; max-width: 680px; }
.topic-list { list-style: none; padding: 0; margin: 10px 0 24px; border-top: 1px solid var(--line); max-width: 680px; }
.topic-list li { display: flex; gap: 12px; align-items: baseline; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.topic-list li::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: #7eabc7; flex-shrink: 0; transform: translateY(-2px); }

/* ---------- Footer ---------- */
footer {
  display: flex;
  align-items: center;
  gap: 40px;
  border-top: 1px solid var(--line);
  padding: 25px 40px;
  font-size: 10px;
  color: #7890a1;
}
.footer-brand { display: flex; align-items: center; gap: 16px; margin-right: auto; }
.footer-brand img { width: 60px; height: 60px; object-fit: contain; }
.footer-brand p { font-size: 12px; color: var(--ink); margin: 0; }
.footer-brand small { display: block; color: #8a9eac; font-size: 9px; line-height: 1.8; }
.footer-contact { line-height: 1.8; }
.footer-contact b { color: var(--ink); font-weight: 500; }
.footer-institutions { display: flex; align-items: center; gap: 24px; flex-shrink: 0; }
.footer-institutions a { display: flex; align-items: center; }
.footer-institutions img { display: block; object-fit: contain; height: 52px; width: auto; }

/* ---------- Responsive ---------- */
@media (min-width: 1500px) {
  .site-header, main, footer { max-width: 1360px; }
}
@media (max-width: 1240px) {
  .site-header { flex-wrap: wrap; gap: 16px 24px; padding: 14px 40px 0; }
  nav { order: 3; width: 100%; padding: 10px 0 8px; border-top: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
  nav::-webkit-scrollbar { display: none; }
}
@media (max-width: 1000px) {
  .campus-hero { gap: 28px; }
  .campus-hero h1, h1 { font-size: 37px; }
  .intro-campus figure img { min-height: 400px; }
  .people-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .project-side { width: 170px; }
  footer { flex-wrap: wrap; gap: 20px 32px; }
  .footer-brand { width: 100%; }
}
@media (max-width: 700px) {
  .site-header { padding: 10px 22px 0; gap: 12px 16px; }
  .logo-link img { width: 52px; height: 52px; }
  .logo-link > span { font-size: 13px; padding-left: 12px; }
  .logo-link small { font-size: 9px; }
  .header-group { padding-left: 13px; }
  .header-group > span { display: none; }
  nav { gap: 24px; }
  .campus-hero { grid-template-columns: 1fr; padding: 28px 22px 35px; gap: 21px; }
  .campus-hero .intro-copy { padding: 0; }
  .campus-hero h1, h1 { font-size: 34px; margin: 18px 0; }
  .intro-copy > p, .page-intro p { font-size: 13px; line-height: 1.9; }
  .intro-campus figure img { min-height: 0; height: 260px; }
  .page-intro { padding: 34px 22px 30px; }
  .section { padding: 34px 22px; }
  .section-heading { align-items: flex-start; flex-direction: column; gap: 7px; }
  h2 { font-size: 25px; }
  .kicker { font-size: 8px; }
  .people-lead { flex-direction: column; gap: 20px; }
  .people-lead > img { width: 110px; height: 125px; }
  .people-lead p, .prose p { font-size: 13px; }
  .banner-card { grid-template-columns: 1fr; gap: 18px; }
  .publication-grid.two { grid-template-columns: 1fr; }
  .paper-entry { grid-template-columns: 1fr; gap: 4px; }
  .people-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 12px; }
  .person-card { gap: 10px; }
  .person-card > img { width: 42px; height: 42px; }
  .person-card h4 { font-size: 12px; }
  .person-card small, .person-card .person-work { font-size: 10px; }
  .project-entry-header { flex-direction: column; gap: 6px; }
  .project-side { width: 100%; text-align: left; display: flex; align-items: center; flex-wrap: wrap; gap: 10px 18px; }
  .project-side > span { margin: 0; }
  .project-side .avatar-stack { justify-content: flex-start; margin: 0; }
  .project-entry h3 { font-size: 18px; }
  .book-layout { grid-template-columns: 1fr; gap: 26px; }
  .book-layout img { max-width: 220px; }
  footer { padding: 18px 22px; gap: 16px; }
  .footer-institutions img { height: 42px; }
}
@media (max-width: 340px) {
  .people-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
