:root {
  --ink: #22272b;
  --muted: #626b73;
  --rule: #d9dee2;
  --paper: #ffffff;
  --soft: #f6f8f9;
  --link: #1679b8;
  --blue: #e8f1f7;
  --blue-line: #7fa6c1;
  --peach: #f9eadf;
  --peach-line: #d9a17a;
  --green: #e8f2eb;
  --green-line: #83aa92;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 4.5rem;
}

body {
  color: var(--ink);
  font-family: "Noto Sans", Arial, sans-serif;
  line-height: 1.65;
}

a {
  color: var(--link);
}

a:hover {
  color: #0d5e92;
  text-decoration: underline;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid #f2b765;
  outline-offset: 3px;
}

.skip-link {
  background: #111;
  color: #fff;
  left: 1rem;
  padding: 0.65rem 1rem;
  position: fixed;
  top: -5rem;
  z-index: 100;
}

.skip-link:focus {
  color: #fff;
  top: 1rem;
}

.project-navbar {
  border-bottom: 1px solid #eceff1;
  min-height: 3.25rem;
}

.project-navbar .navbar-menu {
  justify-content: center;
}

.project-navbar .navbar-start {
  flex-grow: 0;
}

.project-navbar .navbar-item {
  color: #4d565e;
  font-size: 0.93rem;
  font-weight: 500;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}

.project-navbar .navbar-item:hover {
  background: transparent;
  color: #111;
  text-decoration: none;
}

.project-navbar .navbar-burger {
  background: transparent;
  border: 0;
  border-radius: 0;
  color: #4d565e;
}

.publication-header .hero-body {
  padding-bottom: 2rem;
  padding-top: 3.5rem;
}

.publication-title,
.publication-authors,
.publication-affiliation,
.publication-venue,
.teaser figcaption,
.title {
  font-family: "Google Sans", "Noto Sans", Arial, sans-serif;
}

.publication-title {
  font-size: clamp(2.1rem, 5vw, 3.3rem) !important;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.12;
  margin: 0 auto 1.5rem !important;
  max-width: 980px;
}

.publication-authors {
  line-height: 1.8;
  margin-bottom: 0.15rem;
}

.publication-authors a {
  color: #1590d0 !important;
}

.author-block {
  display: inline-block;
  margin: 0 0.18rem;
}

.publication-affiliation {
  color: #4d565e;
  margin-top: 0.15rem;
}

.publication-venue {
  color: #343a40;
  font-weight: 700;
  margin-top: 0.45rem;
}

.publication-links {
  margin-top: 1.25rem;
}

.link-block {
  display: inline-block;
  margin: 0.25rem 0.18rem;
}

.publication-links .button {
  align-items: center;
  gap: 0.45rem;
  min-width: 7rem;
}

.button-icon {
  fill: currentColor;
  height: 1.05rem;
  width: 1.05rem;
}

.teaser .hero-body {
  padding-bottom: 3.25rem;
  padding-top: 0;
}

.hero-example-container {
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.hero-example {
  margin: 0 auto;
  max-width: 1420px;
  text-align: center;
}

.hero-example-grid {
  align-items: center;
  display: grid;
  gap: 0.9rem;
  grid-template-columns: minmax(0, 3fr) 30px minmax(0, 5fr) 30px minmax(0, 3fr);
}

.hero-example-panel {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(44, 57, 66, 0.06);
  padding: 1rem;
  text-align: left;
}

.hero-panel-heading {
  align-items: center;
  display: flex;
  gap: 0.7rem;
  margin-bottom: 0.85rem;
}

.hero-stage-number {
  align-items: center;
  background: #313b42;
  border-radius: 50%;
  color: #fff;
  display: inline-flex;
  flex: 0 0 1.8rem;
  font-family: "Google Sans", "Noto Sans", sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  height: 1.8rem;
  justify-content: center;
}

.hero-panel-heading div {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.hero-panel-kicker,
.hero-reasoning > span,
.hero-search > span,
.hero-returned > span {
  color: #68747c;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.hero-panel-heading strong {
  color: #273139;
  font-family: "Google Sans", "Noto Sans", sans-serif;
  font-size: 0.98rem;
}

.hero-input-panel {
  background: #f5faff;
  border-color: #b9d2e3;
}

.hero-task-crop {
  aspect-ratio: 872 / 468;
  border: 1px solid #b9d2e3;
  border-radius: 9px;
  overflow: hidden;
}

.hero-task-crop img {
  display: block;
  height: auto;
  width: 100%;
}

.hero-image-clue {
  align-items: center;
  background: var(--peach);
  border: 1px solid var(--peach-line);
  border-radius: 999px;
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0.5rem;
  justify-content: center;
  margin: 1rem auto 0;
  padding: 0.55rem 0.85rem;
  position: relative;
  text-align: center;
  width: fit-content;
}

.hero-image-clue::before {
  border-bottom: 7px solid var(--peach-line);
  border-left: 7px solid transparent;
  border-right: 7px solid transparent;
  content: "";
  left: 50%;
  position: absolute;
  top: -8px;
  transform: translateX(-50%);
}

.hero-image-clue span {
  color: #8a5633;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.hero-image-clue strong {
  color: #703c20;
  font-size: 0.84rem;
}

.hero-flow-arrow {
  color: #4d789b;
  font-family: "Google Sans", "Noto Sans", sans-serif;
  font-size: 2.2rem;
  font-weight: 500;
  text-align: center;
}

.hero-trace-panel {
  padding: 0.9rem;
}

.hero-trace-heading {
  margin-bottom: 0.65rem;
  padding: 0 0.1rem;
}

.hero-round {
  border-top: 1px dashed #b6c0c6;
  display: grid;
  gap: 0.32rem;
  grid-template-columns: minmax(0, 1fr);
  padding: 0.65rem 0.1rem 0;
}

.hero-round + .hero-round {
  margin-top: 0.65rem;
}

.hero-round h3 {
  color: #313b42;
  font-family: "Google Sans", "Noto Sans", sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
  margin: 0 0 0.05rem;
}

.hero-reasoning,
.hero-search,
.hero-returned {
  border: 1px solid;
  border-radius: 7px;
  padding: 0.42rem 0.58rem;
}

.hero-reasoning {
  background: var(--peach);
  border-color: var(--peach-line);
}

.hero-reasoning p {
  color: #39434a;
  font-size: 0.73rem;
  line-height: 1.35;
  margin: 0.08rem 0 0;
}

.hero-search {
  align-items: baseline;
  background: var(--blue);
  border-color: var(--blue-line);
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0.55rem;
}

.hero-search code {
  background: transparent;
  color: #273139;
  font-size: 0.72rem;
  font-weight: 600;
  overflow-wrap: anywhere;
  padding: 0;
}

.hero-returned {
  background: #f4f6f7;
  border-color: #c4ccd1;
}

.hero-returned.is-confirmed {
  background: var(--green);
  border-color: var(--green-line);
}

.hero-result-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.28rem;
  margin-top: 0.22rem;
}

.hero-result-pills > span {
  background: #fff;
  border: 1px solid #d5dadd;
  border-radius: 999px;
  color: #4b565e;
  font-size: 0.64rem;
  line-height: 1.25;
  padding: 0.22rem 0.48rem;
}

.hero-result-pills > .is-relevant {
  background: #e4f1e8;
  border-color: #8eb69b;
  color: #285f3e;
  font-weight: 700;
}

.hero-result-pills > .hero-more-pill {
  min-width: 1.7rem;
  text-align: center;
}

.hero-output-panel {
  background: var(--green);
  border-color: var(--green-line);
}

.hero-wikipedia-card {
  align-items: center;
  background: #fff;
  border: 1px solid #cad4ce;
  border-radius: 9px;
  display: flex;
  gap: 0.65rem;
  padding: 0.8rem;
}

.hero-wikipedia-mark {
  align-items: center;
  background: #f1f3f4;
  border: 1px solid #d4d8da;
  border-radius: 6px;
  color: #687078;
  display: inline-flex;
  flex: 0 0 2rem;
  font-family: Georgia, serif;
  font-size: 1.3rem;
  font-weight: 700;
  height: 2rem;
  justify-content: center;
}

.hero-wikipedia-card div {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.hero-wikipedia-card strong {
  color: #253029;
  font-family: Georgia, serif;
  font-size: 0.98rem;
  line-height: 1.25;
}

.hero-wikipedia-card div span {
  color: #687169;
  font-size: 0.67rem;
  margin-top: 0.15rem;
}

.hero-animation-stage {
  animation-duration: 0.55s;
  animation-fill-mode: both;
  animation-iteration-count: 1;
  animation-name: hero-stage-enter;
  animation-timing-function: ease;
  will-change: opacity, transform;
}

.hero-animation-stage[data-hero-stage="1"] {
  animation-delay: 0.25s;
}

.hero-animation-stage[data-hero-stage="2"] {
  animation-delay: 1.4s;
}

.hero-animation-stage[data-hero-stage="3"] {
  animation-delay: 2.55s;
}

.hero-animation-stage[data-hero-stage="4"] {
  animation-delay: 3.7s;
}

@keyframes hero-stage-enter {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.framework-figure img {
  display: block;
  height: auto;
  margin: 0 auto;
  width: 100%;
}

.framework-figure picture {
  display: block;
}

figcaption {
  color: var(--muted);
  font-size: 0.91rem;
  line-height: 1.5;
  margin: 0.8rem auto 0;
  max-width: 780px;
  text-align: center;
}

.section {
  padding-bottom: 5rem;
  padding-top: 5rem;
}

.section.is-light {
  background: var(--soft);
}

.abstract-section {
  border-top: 1px solid #eff1f2;
}

.publication-body > .title {
  color: var(--ink);
  margin-bottom: 2rem;
}

.prose {
  font-size: 1.05rem;
  margin-left: auto;
  margin-right: auto;
  max-width: 780px;
}

.prose p {
  margin-bottom: 1.25em;
}

.abstract-section .content > p {
  font-size: 1.05rem;
  margin-left: auto;
  margin-right: auto;
  max-width: 850px;
  text-align: justify;
}

.publication-figure {
  margin: 3rem auto;
  text-align: center;
  width: 100%;
}

.publication-figure img {
  display: block;
  height: auto;
  margin: 0 auto;
  max-width: 100%;
}

.figure-medium {
  max-width: 760px;
}

.figure-wide {
  max-width: 1120px;
}

.figure-columns {
  align-items: center;
  margin-top: 1.25rem;
}

.figure-columns .publication-figure {
  margin-bottom: 1rem;
  margin-top: 1rem;
}

.framework-figure {
  margin: 3rem auto;
  max-width: 1220px;
}

.method-details {
  margin-top: 2.5rem;
}

.result-table-wrap {
  margin: 2.25rem auto;
  max-width: 680px;
}

.result-table {
  background: #fff;
  margin: 0 auto;
  text-align: center;
  width: 100%;
}

.result-table caption {
  color: var(--muted);
  font-size: 0.9rem;
  margin-bottom: 0.6rem;
}

.result-table th {
  color: #30383e;
  text-align: center !important;
}

.results-pair .column:last-child .publication-figure {
  width: 100%;
}

.behavior-figures {
  margin-top: 1.5rem;
}

.behavior-figures .publication-figure {
  margin-bottom: 0;
  margin-top: 1rem;
}

.code-example,
.citation-box {
  margin: 2.25rem auto;
  max-width: 780px;
  position: relative;
}

pre {
  background: #282c34;
  border-radius: 6px;
  color: #edf1f4;
  font-size: 0.9rem;
  line-height: 1.55;
  overflow-x: auto;
  padding: 1.5rem;
}

.citation-box #copy-bibtex {
  position: absolute;
  right: 0.75rem;
  top: 0.75rem;
  z-index: 1;
}

.citation-box pre {
  padding-right: 8.5rem;
}

.acknowledgments {
  border-top: 1px solid var(--rule);
  margin-top: 3.5rem;
  padding-top: 2.5rem;
}

.acknowledgments .title {
  margin-bottom: 1.25rem;
}

.project-footer {
  background: #fff;
  border-top: 1px solid #e4e8ea;
  color: var(--muted);
  font-size: 0.9rem;
  padding: 2.5rem 1.5rem;
}

.project-footer p + p {
  margin-top: 0.45rem;
}

@media screen and (max-width: 1180px) {
  .hero-example-grid {
    grid-template-columns: 1fr;
    margin: 0 auto;
    max-width: 720px;
  }

  .hero-flow-arrow {
    line-height: 1;
    transform: rotate(90deg);
  }
}

@media screen and (max-width: 1023px) {
  .project-navbar .navbar-brand {
    margin-left: auto;
  }

  .project-navbar .navbar-menu {
    border-top: 1px solid #eceff1;
    box-shadow: none;
  }

  .project-navbar .navbar-item {
    justify-content: center;
    padding-bottom: 0.8rem;
    padding-top: 0.8rem;
  }

}

@media screen and (max-width: 768px) {
  html {
    scroll-padding-top: 1rem;
  }

  .publication-header .hero-body {
    padding: 2.5rem 1.15rem 1.5rem;
  }

  .publication-title {
    font-size: 2.15rem !important;
  }

  .publication-authors,
  .publication-affiliation,
  .publication-venue {
    font-size: 1.05rem !important;
  }

  .teaser .hero-body {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .section {
    padding: 3.5rem 1.1rem;
  }

  .abstract-section .content > p {
    text-align: left;
  }

  .hero-example-container {
    padding-left: 0;
    padding-right: 0;
  }

  .hero-example-panel {
    border-radius: 9px;
    padding: 0.8rem;
  }

  .hero-panel-heading strong {
    font-size: 0.9rem;
  }

  .hero-round {
    padding-top: 0.6rem;
  }

  .hero-reasoning p,
  .hero-search code {
    font-size: 0.76rem;
  }

  .prose {
    font-size: 1rem;
  }

  .publication-figure {
    margin: 2.25rem auto;
  }

  .figure-columns,
  .behavior-figures,
  .results-pair {
    display: block;
  }

  .framework-figure {
    margin: 2.25rem auto;
  }

  .citation-box #copy-bibtex {
    margin-bottom: 0.75rem;
    position: static;
  }

  .citation-box pre {
    padding-right: 1.25rem;
  }

  pre {
    font-size: 0.78rem;
    padding: 1.25rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .hero-animation-stage {
    animation: none;
    opacity: 1;
    transform: none;
  }
}
