:root {
  --page-ink: #2d2c30;
  --page-muted: #66626a;
  --page-line: #e9e5e6;
  --page-accent: #98505c;
  --page-surface: #faf9f8;
}

body {
  color: var(--page-ink);
  background: #fff;
  font-family: 'Noto Sans', sans-serif;
  line-height: 1.7;
}

a {
  color: var(--page-accent);
  text-underline-offset: 0.2em;
}

a:hover {
  color: #713a45;
  text-decoration: underline;
}

:where(a, button, input, [tabindex]):focus-visible {
  outline: 2px solid var(--page-accent);
  outline-offset: 4px;
}

.container.is-widescreen {
  max-width: 1120px;
}

.section {
  padding: 0 1.5rem 3.75rem;
}

.section > .container {
  padding-top: 2.25rem;
  border-top: 1px solid var(--page-line);
}

.section .title {
  margin-bottom: 1.5rem;
  color: var(--page-ink);
  font-size: 1.75rem;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.25;
  text-align: left !important;
}

.section .title[id] {
  scroll-margin-top: 2rem;
}

.content.has-text-justified {
  text-align: left !important;
}

.hero .hero-body {
  padding: 4.75rem 1.5rem 3rem;
}

.hero .publication-title {
  max-width: 980px;
  margin: 0 auto 1.75rem;
  color: var(--page-ink);
  font-size: clamp(2rem, 4.1vw, 2.9rem);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.15;
  text-wrap: balance;
}

.publication-meta {
  margin-bottom: 1rem;
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  line-height: 1.35;
}

.publication-author-list {
  font-size: 1.4rem;
  font-weight: 500;
  line-height: 1.9;
}

.publication-author-list a {
  text-decoration: underline;
  text-decoration-color: #d8bcc2;
  text-decoration-thickness: 1px;
}

.publication-author-list a:hover {
  text-decoration-color: currentColor;
}

.publication-authors sup {
  margin-left: 0.08em;
  font-size: 0.7em;
}

.publication-affiliation {
  margin-top: 0.6rem;
  color: var(--page-muted);
  font-size: 1rem;
}

.publication-resources {
  margin-top: 1.5rem;
}

.abstract-section > .container {
  max-width: 780px;
  padding-top: 1rem;
  border-top: 0;
}

.abstract-section .columns {
  margin: 0;
}

.abstract-section .column {
  width: 100%;
  padding: 0;
}

.abstract-section .content {
  color: #4b484f;
  font-size: 1.02rem;
  line-height: 1.85;
}

.link-block a,
.link-block .is-disabled {
    margin-top: 5px;
    margin-bottom: 5px;
}

.is-disabled {
  pointer-events: none;
  cursor: not-allowed;
  opacity: 0.45;
}

.teaser-carousel-section {
  padding-top: 1rem;
  padding-bottom: 3rem;
}

.teaser-carousel {
  position: relative;
  max-width: 720px;
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid #dbdbdb;
  border-radius: 10px;
  background: #f7f7f7;
}

.teaser-slides {
  aspect-ratio: 1 / 1;
}

.teaser-slide {
  display: none;
  width: 100%;
  height: 100%;
  margin: 0;
  align-items: center;
  justify-content: center;
}

.teaser-slide.is-active {
  display: flex;
}

.image-compare {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #ededed;
}

.compare-image {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  user-select: none;
  pointer-events: none;
}

.compare-before {
  clip-path: inset(0 50% 0 0);
}

.compare-divider {
  position: absolute;
  z-index: 2;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 3px;
  background: #fff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.2);
  transform: translateX(-50%);
  pointer-events: none;
}

.compare-divider::after {
  content: "↔";
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 2px solid #fff;
  border-radius: 50%;
  color: #fff;
  background: rgba(0, 0, 0, 0.45);
  font-size: 1.15rem;
  transform: translate(-50%, -50%);
}

.compare-range {
  position: absolute;
  z-index: 3;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
}

.image-compare:focus-within {
  box-shadow: inset 0 0 0 3px rgba(50, 115, 220, 0.55);
}

.compare-label {
  position: absolute;
  z-index: 2;
  top: 1rem;
  padding: 0.3rem 0.65rem;
  border-radius: 4px;
  color: #fff;
  background: rgba(0, 0, 0, 0.58);
  font-size: 0.78rem;
  font-weight: 700;
  pointer-events: none;
}

.compare-label-before { left: 1rem; }
.compare-label-after { right: 1rem; }

.teaser-slide.is-missing .compare-image,
.teaser-slide.is-missing .compare-divider,
.teaser-slide.is-missing .compare-range,
.teaser-slide.is-missing .compare-label {
  display: none;
}

.teaser-missing {
  display: none;
  width: 100%;
  height: 100%;
  align-items: center;
  justify-content: center;
  color: #777;
  font-size: 0.95rem;
}

.teaser-slide.is-missing .teaser-missing {
  display: flex;
}

.teaser-thumbnails {
  display: flex;
  max-width: 720px;
  margin: 1rem auto 0;
  justify-content: center;
  gap: 0.8rem;
}

.teaser-thumbnail {
  width: 92px;
  aspect-ratio: 1 / 1;
  padding: 0;
  overflow: hidden;
  border: 3px solid transparent;
  border-radius: 8px;
  background: #eee;
  cursor: pointer;
  opacity: 0.62;
  transition: border-color 160ms ease, opacity 160ms ease, transform 160ms ease;
}

.teaser-thumbnail:hover {
  opacity: 0.9;
}

.teaser-thumbnail.is-active {
  border-color: #a83f58;
  opacity: 1;
  transform: translateY(-2px);
}

.teaser-thumbnail img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rbox-demo-section {
  padding-bottom: 3.75rem;
}

.rbox-demo-heading {
  margin-bottom: 2rem;
}

.rbox-demo-heading .subtitle {
  max-width: 720px;
  margin-right: auto;
  margin-left: 0;
  color: var(--page-muted);
  font-size: 1rem;
  line-height: 1.7;
  text-align: left;
}

.rbox-demo-card {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(300px, 0.8fr);
  overflow: hidden;
  border: 1px solid var(--page-line);
  border-radius: 12px;
  background: #fff;
}

.rbox-canvas-wrap {
  padding: 1.25rem;
  border-right: 1px solid var(--page-line);
  background: var(--page-surface);
}

#rbox-demo {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid #e5e5e5;
  border-radius: 6px;
  background: #fff;
  touch-action: none;
}

.prediction-box {
  fill: rgba(50, 115, 220, 0.10);
  stroke: #3273dc;
  stroke-width: 6;
  cursor: grab;
  touch-action: none;
}

.reference-box {
  fill: none;
  stroke: #fff;
  stroke-width: 3;
  stroke-dasharray: 9 6;
  filter: drop-shadow(0 0 2px rgba(0, 0, 0, 0.9));
  pointer-events: none;
}

.prediction-box:active {
  cursor: grabbing;
}

.prediction-box:focus {
  outline: none;
  stroke-width: 9;
}

.intersection-box {
  fill: rgba(121, 87, 213, 0.22);
  stroke: none;
  pointer-events: none;
}

.rbox-case-picker {
  display: flex;
  margin-top: 0.9rem;
  justify-content: center;
  gap: 0.65rem;
}

.rbox-case {
  display: grid;
  min-width: 112px;
  padding: 0.3rem 0.6rem 0.3rem 0.3rem;
  grid-template-columns: 44px auto;
  align-items: center;
  gap: 0.5rem;
  border: 2px solid transparent;
  border-radius: 8px;
  color: #555;
  background: #fff;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  opacity: 0.68;
  transition: border-color 160ms ease, opacity 160ms ease, transform 160ms ease;
}

.rbox-case:hover,
.rbox-case:focus-visible {
  opacity: 1;
}

.rbox-case:focus-visible {
  outline: 2px solid #3273dc;
  outline-offset: 2px;
}

.rbox-case.is-active {
  border-color: #3273dc;
  opacity: 1;
  transform: translateY(-1px);
}

.rbox-case img {
  display: block;
  width: 44px;
  height: 36px;
  border-radius: 5px;
  object-fit: cover;
}

.rbox-legend {
  display: flex;
  margin-top: 0.9rem;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem 1.25rem;
  color: #555;
  font-size: 0.85rem;
}

.rbox-legend > span {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.legend-line,
.legend-fill {
  display: inline-block;
  width: 22px;
  height: 4px;
}

.reference-legend {
  height: 0;
  border-top: 3px dashed #777;
  background: transparent;
}
.prediction-legend { background: #3273dc; }
.overlap-legend { height: 12px; background: rgba(121, 87, 213, 0.35); }

.rbox-controls {
  display: flex;
  padding: 2rem;
  flex-direction: column;
  justify-content: center;
}

.rbox-controls > label {
  margin-bottom: 0.6rem;
  color: #363636;
  font-weight: 600;
}

#rotation-slider {
  width: 100%;
  min-height: 24px;
  accent-color: #3273dc;
  cursor: ew-resize;
}

.slider-scale {
  display: flex;
  margin-top: 0.2rem;
  justify-content: space-between;
  color: #777;
  font-size: 0.78rem;
}

.drag-hint {
  margin: 0.7rem 0 1.5rem;
  color: #777;
  font-size: 0.82rem;
}

.rbox-metrics {
  border-top: 1px solid #e5e5e5;
}

.metric-row {
  display: flex;
  padding: 0.8rem 0;
  align-items: baseline;
  justify-content: space-between;
  border-bottom: 1px solid #e5e5e5;
  gap: 1rem;
}

.metric-row span {
  color: #555;
  font-size: 0.92rem;
}

.metric-row output {
  color: #222;
  font-family: monospace;
  font-size: 1.2rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.metric-result {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.55rem;
}

.threshold-badge {
  min-width: 92px;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  font-size: 0.72rem !important;
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
}

.threshold-badge.is-pass {
  color: #257942;
  background: #e8f7ed;
}

.threshold-badge.is-fail {
  color: #b4233f;
  background: #fdecef;
}

.oiou-row output {
  color: #7957d5;
}

.oiou-formula {
  margin-top: 1.25rem;
  padding: 0.75rem 0.5rem;
  border: 1px solid #e6e6e6;
  border-radius: 8px;
  color: #333;
  background: #fafafa;
}

.oiou-formula math {
  margin: 0 auto;
  font-family: 'STIX Two Math', 'Cambria Math', 'Times New Roman', serif;
  font-size: clamp(0.82rem, 2.2vw, 1rem);
}

.pipeline-section {
  padding-bottom: 3.75rem;
}

.gradorient-highlight {
  color: #b85c65;
  background: linear-gradient(90deg, #a84f5a 0%, #d4866a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.pipeline-figure {
  overflow: hidden;
  background: #fff;
}

.pipeline-figure img {
  display: block;
  width: 100%;
  height: auto;
}

.pipeline-description {
  width: 100%;
  margin: 1.25rem 0 0;
  color: var(--page-muted);
  font-size: 0.94rem;
  line-height: 1.75;
}

.results-section {
  padding-bottom: 3.75rem;
}

.quantitative-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3.25rem;
}

.quantitative-grid figure {
  margin: 0;
  min-width: 0;
}

.table-scroll {
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: thin;
  scrollbar-color: #c5b9bc var(--page-surface);
}

.quantitative-grid img {
  display: block;
  width: 100%;
  height: auto;
  background: #fff;
}

.qualitative-figure {
  margin: 0;
}

.qualitative-figure img {
  display: block;
  width: 100%;
  height: auto;
  background: #fff;
}

.result-caption {
  width: 100%;
  margin: 1rem 0 0;
  color: var(--page-muted);
  font-size: 0.92rem;
  line-height: 1.75;
  text-align: left;
}

.caption-label {
  color: var(--page-ink);
  font-weight: 600;
}

#BibTeX pre {
  padding: 1.5rem;
  border: 1px solid var(--page-line);
  border-radius: 8px;
  background: var(--page-surface);
  color: #49444c;
  font-size: 0.85rem;
  line-height: 1.8;
  tab-size: 2;
}

.footer {
  padding: 2.25rem 1.5rem 2.75rem;
  border-top: 1px solid var(--page-line);
  background: #fff;
  color: var(--page-muted);
  font-size: 0.8rem;
}

.footer .content p:not(:last-child) {
  margin-bottom: 0.5rem;
}

.figure-zoom {
  position: relative;
  display: block;
  cursor: zoom-in;
}
.figure-zoom::after {
  content: 'Enlarge ↗';
  display: block;
  width: fit-content;
  margin: 8px 0 0 auto;
  padding: 3px 9px;
  border: 1px solid #ded9dc;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.94);
  color: #49444c;
  font: 12px/1.6 'Noto Sans', sans-serif;
}
.figure-zoom:focus-visible,
.utility-button:focus-visible {
  outline: 3px solid #a84f5a;
  outline-offset: 3px;
}
.utility-button {
  border: 1px solid #d9d2d5;
  border-radius: 6px;
  padding: 8px 12px;
  background: #fff;
  color: #49444c;
  font: inherit;
  font-size: 14px;
  cursor: pointer;
}
.utility-button:hover { background: #f7f4f5; }
.utility-button[hidden] { display: none; }
.citation-heading,
.figure-dialog-header,
.figure-dialog-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.citation-heading { flex-wrap: wrap; }
#BibTeX .citation-heading h2 { margin: 0; }
.copy-status {
  min-height: 1.5em;
  margin: 8px 0;
  color: #62666c;
  font-size: 14px;
}
.figure-dialog {
  width: 94vw;
  max-width: 1600px;
  height: 92vh;
  max-height: 92dvh;
  padding: 0;
  border: 1px solid #ded9dc;
  border-radius: 10px;
  background: #fff;
  color: #202124;
}
.figure-dialog[open] { display: flex; flex-direction: column; }
.figure-dialog::backdrop { background: rgba(24, 22, 27, 0.72); }
.figure-dialog-header { padding: 14px 18px; border-bottom: 1px solid #e7e3e5; }
.figure-dialog-header h2 { margin: 0; font-size: 15px; font-weight: 600; }
.figure-dialog-actions { flex-shrink: 0; }
.figure-dialog-view { flex: 1; min-height: 0; padding: 16px; overflow: auto; }
.figure-dialog-view img { display: block; width: 100%; height: 100%; object-fit: contain; }
.figure-dialog.is-zoomed .figure-dialog-view img { width: auto; height: auto; max-width: none; }
body.figure-viewer-open { overflow: hidden; }
@media (max-width: 600px) {
  .figure-dialog-header { align-items: flex-start; flex-direction: column; padding: 12px; }
  .figure-dialog-actions { width: 100%; }
  .figure-dialog-view { padding: 8px; }
}

.bibtex-placeholder {
  min-height: 8rem;
  display: flex;
  align-items: center;
  color: #777;
}

@media screen and (max-width: 768px) {
  .section {
    padding-right: 1.25rem;
    padding-bottom: 2.75rem;
    padding-left: 1.25rem;
  }

  .section > .container {
    padding-top: 1.75rem;
  }

  .section .title {
    font-size: 1.5rem;
  }

  .abstract-section > .container {
    padding-top: 0.75rem;
  }

  .abstract-section .content {
    font-size: 0.98rem;
    line-height: 1.8;
  }

  .quantitative-grid {
    gap: 2.25rem;
  }

  .quantitative-grid img {
    min-width: 900px;
  }

  .table-scroll {
    padding-bottom: 0.65rem;
  }

  .publication-author-list {
    display: grid;
    grid-template-columns: repeat(2, max-content);
    justify-content: center;
    gap: 0.1rem 0.65rem;
    font-size: 1.2rem;
  }

  .rbox-demo-card {
    grid-template-columns: 1fr;
  }

  .rbox-canvas-wrap {
    border-right: 0;
    border-bottom: 1px solid var(--page-line);
  }

  .rbox-controls {
    padding: 1.5rem;
  }

  .metric-row {
    align-items: flex-start;
  }

  .metric-result {
    flex-direction: column;
    align-items: flex-end;
    gap: 0.25rem;
  }

  .hero .publication-title {
    font-size: clamp(1.75rem, 7.3vw, 2.4rem);
    line-height: 1.18;
  }

  .hero .hero-body {
    padding: 3rem 1.25rem 2rem;
  }

  .author-notes .author-block {
    display: block;
    margin: 0.15rem 0 0;
  }

  .result-caption {
    text-align: left;
  }
}

.publication-title,
.publication-authors {
  font-family: 'Google Sans', sans-serif;
}

.publication-title {
  line-height: 1.1;
}

.publication-venue {
  width: fit-content;
  color: #555;
  font-weight: 700;
}

.publication-venue-name {
  margin-right: 0.2em;
  color: #a84f5a;
}

.author-block {
  display: inline-block;
}

.author-notes {
  margin-top: 0.5rem;
  color: var(--page-muted);
  font-size: 0.9rem;
}

.author-notes .author-block + .author-block {
  margin-left: 1rem;
}

.resource-icon {
  width: 1.05em;
  height: 1.05em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

@media screen and (max-width: 768px) {
  .author-notes .author-block + .author-block {
    margin-left: 0;
  }
}
