:root {
  --ink: #14211b;
  --muted: #647169;
  --paper: #f5f2e9;
  --white: #fffdf8;
  --green: #1d6b4f;
  --green-dark: #124a38;
  --green-soft: #dce9df;
  --line: #d8ddd5;
  --orange: #df6b3d;
  --shadow: 0 18px 50px rgba(24, 45, 35, 0.08);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "DM Sans", sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.site-header {
  max-width: 1240px;
  height: 78px;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  letter-spacing: -0.02em;
}

.brand-mark {
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  color: var(--white);
  background: var(--green);
  font-family: "Newsreader", serif;
  font-size: 20px;
}

.method-link, .site-nav a {
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 24px;
}

.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--green); }
.site-nav a[aria-current="page"] { position: relative; }
.site-nav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -7px;
  left: 0;
  height: 2px;
  border-radius: 2px;
  background: var(--green);
}

.hero {
  max-width: 1240px;
  margin: 0 auto;
  padding: 92px 28px 88px;
  position: relative;
}

.hero::after {
  content: "";
  position: absolute;
  z-index: -1;
  top: 35px;
  right: 5%;
  width: 300px;
  height: 300px;
  border: 1px solid rgba(29, 107, 79, 0.14);
  border-radius: 50%;
  box-shadow: 0 0 0 48px rgba(29, 107, 79, 0.035), 0 0 0 96px rgba(29, 107, 79, 0.025);
}

.eyebrow, .section-kicker {
  margin: 0 0 16px;
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

h1, h2, h3, p { margin-top: 0; }

h1 {
  max-width: 850px;
  margin-bottom: 24px;
  font-family: "Newsreader", serif;
  font-size: clamp(54px, 8vw, 96px);
  font-weight: 600;
  line-height: 0.94;
  letter-spacing: -0.055em;
}

h1 span { color: var(--green); }

.hero-copy {
  max-width: 650px;
  margin-bottom: 28px;
  color: var(--muted);
  font-size: clamp(17px, 2vw, 20px);
  line-height: 1.65;
}

.status-line {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--muted);
  font-size: 13px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #33a36f;
  box-shadow: 0 0 0 4px rgba(51, 163, 111, 0.12);
}

.explorer {
  padding: 70px max(28px, calc((100vw - 1184px) / 2)) 90px;
  background: var(--white);
}

.explorer-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 32px;
}

h2 {
  margin-bottom: 0;
  font-family: "Newsreader", serif;
  font-size: clamp(36px, 5vw, 54px);
  line-height: 1;
  letter-spacing: -0.035em;
}

.search-box {
  width: min(100%, 390px);
  height: 48px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}

.search-box:focus-within { border-color: var(--green); box-shadow: 0 0 0 3px rgba(29, 107, 79, 0.1); }

.search-box svg {
  width: 20px;
  fill: none;
  stroke: var(--muted);
  stroke-linecap: round;
  stroke-width: 1.8;
}

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
  font: inherit;
  font-size: 14px;
}

.filters {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.filter-group { display: flex; gap: 8px; flex-wrap: wrap; }

.select-filters {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.filter-chip, #clear-filters, #clear-placement-filters {
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: #fff;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.filter-chip.active {
  color: #fff;
  border-color: var(--green);
  background: var(--green);
}

.select-wrap select {
  max-width: 220px;
  height: 40px;
  padding: 0 34px 0 13px;
  border: 1px solid var(--line);
  border-radius: 9px;
  color: var(--ink);
  background: #fff;
  font: inherit;
  font-size: 13px;
}

.paper-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  padding-top: 28px;
}

.paper-card {
  min-height: 310px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
  align-self: start;
}

.paper-card:hover {
  transform: translateY(-3px);
  border-color: #b9c8bd;
  box-shadow: var(--shadow);
}

.card-top {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 30px;
}

.institution {
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.rank {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 12px;
}

.paper-card h3 {
  margin-bottom: 10px;
  font-family: "Newsreader", serif;
  font-size: 27px;
  line-height: 1.12;
  letter-spacing: -0.025em;
}

.candidate-name {
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 14px;
}

.field-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 18px;
}

.field-tag {
  padding: 5px 9px;
  border-radius: 6px;
  color: var(--green-dark);
  background: var(--green-soft);
  font-size: 11px;
  font-weight: 600;
}

.paper-details {
  margin-bottom: 20px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.paper-details summary {
  padding: 12px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--green);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}

.paper-details summary::-webkit-details-marker { display: none; }
.paper-details summary span::before { content: "+"; font-size: 18px; font-weight: 500; }
.paper-details[open] summary span::before { content: "-"; }

.abstract-content {
  padding: 2px 0 16px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.abstract-content p { margin-bottom: 12px; }
.abstract-content a { color: var(--green); font-weight: 700; text-decoration: none; }
.abstract-placement { display: flex; flex-wrap: wrap; gap: 5px; }
.abstract-placement strong { color: var(--ink); }

.card-links {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 18px;
}

.paper-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #fff;
  background: var(--green);
  padding: 10px 14px;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.profile-link {
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.paper-link:hover { background: var(--green-dark); }
.profile-link:hover { color: var(--green); }

.empty-state {
  margin-top: 28px;
  padding: 80px 24px;
  border: 1px dashed var(--line);
  border-radius: 16px;
  text-align: center;
}

.empty-state h3 { margin-bottom: 8px; font-size: 22px; }
.empty-state p { color: var(--muted); }
#clear-filters { color: #fff; border-color: var(--green); background: var(--green); }

.placement-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  padding-top: 22px;
}

.placement-card {
  min-height: 245px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.placement-card:hover {
  transform: translateY(-3px);
  border-color: #b9c8bd;
  box-shadow: var(--shadow);
}

.placement-card h3 {
  margin-bottom: 14px;
  font-family: "Newsreader", serif;
  font-size: 24px;
  line-height: 1.08;
  letter-spacing: -0.025em;
}

.placement-card .card-top {
  gap: 10px;
  margin-bottom: 14px;
}

.placement-status {
  flex: 0 0 auto;
  padding: 4px 7px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
}

.placement-status.confirmed { color: var(--green-dark); background: var(--green-soft); }
.placement-status.pending { color: #7a675d; background: #eee7df; }

.placement-detail {
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.placement-label {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.placement-destination {
  display: block;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.placement-position {
  margin: 5px 0 0;
  color: var(--green);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.placement-timing {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.placement-links {
  margin-top: auto;
  padding-top: 14px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px 14px;
}

.source-link {
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.pending-card { background: #fcfaf5; }
.pending-card .placement-destination { color: var(--muted); font-weight: 600; }
#clear-placement-filters { color: #fff; border-color: var(--green); background: var(--green); }

.placement-hero {
  padding-bottom: 54px;
}

.placement-hero h1 {
  margin-bottom: 20px;
}

.methodology {
  max-width: 1184px;
  margin: 0 auto;
  padding: 96px 28px;
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 10vw;
}

.method-copy {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.75;
}

.source-links { display: flex; flex-wrap: wrap; gap: 16px 24px; margin-top: 28px; }
.source-links a { color: var(--green); font-size: 14px; font-weight: 700; text-decoration: none; }

footer {
  max-width: 1184px;
  margin: 0 auto;
  padding: 28px;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
}

footer p { margin: 0; }
footer a { text-decoration: none; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 1020px) {
  .placement-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .site-header { height: 66px; padding-inline: 20px; }
  .site-nav { gap: 14px; }
  .site-nav a { font-size: 12px; }
  .hero { padding: 68px 20px 70px; }
  .hero::after { width: 170px; height: 170px; top: 20px; right: 0; }
  h1 { font-size: clamp(42px, 12vw, 58px); }
  .explorer { padding: 58px 20px 70px; }
  .explorer-heading { align-items: stretch; flex-direction: column; }
  .search-box { width: 100%; }
  .filters { align-items: stretch; flex-direction: column; }
  .select-filters { display: grid; grid-template-columns: 1fr; }
  .select-wrap select { width: 100%; max-width: none; }
  .paper-grid { grid-template-columns: 1fr; }
  .paper-card { min-height: 290px; padding: 24px; }
  .placement-grid { grid-template-columns: 1fr; }
  .placement-card { min-height: 0; padding: 18px; }
  .placement-hero { padding-bottom: 48px; }
  .methodology { grid-template-columns: 1fr; gap: 36px; padding: 70px 20px; }
  footer { margin-inline: 20px; padding-inline: 0; flex-direction: column; }
}

@media (max-width: 360px) {
  .brand > span:last-child { display: none; }
  h1 { font-size: 36px; }
}
