:root {
    --ink: #172033;
    --muted: #5f6b7a;
    --light: #f7f9fc;
    --line: #dce3ec;
    --blue: #2463b8;
    --blue-dark: #174a8c;
    --teal: #16857b;
    --orange: #bc6c25;
    --paper: #ffffff;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
    line-height: 1.65;
}

img,
video {
    display: block;
    max-width: 100%;
}

a {
    color: inherit;
}

sup {
    line-height: 0;
}

.page-shell {
    width: min(980px, calc(100% - 32px));
    margin: 0 auto;
    padding: 40px 0 72px;
}

.hero {
    text-align: center;
    padding-bottom: 28px;
}

.venue {
    margin: 0 0 12px;
    color: var(--blue);
    font-size: 1.35rem;
    font-weight: 760;
    letter-spacing: 0.02em;
}

h1 {
    max-width: 920px;
    margin: 0 auto;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2.05rem, 4.7vw, 3.55rem);
    line-height: 1.05;
    font-weight: 760;
    letter-spacing: 0;
}

.tagline {
    max-width: 800px;
    margin: 16px auto 14px;
    color: #26374d;
    font-size: clamp(1.15rem, 2vw, 1.45rem);
    font-weight: 650;
}

.authors {
    max-width: 960px;
    margin: 0 auto;
    color: #21365a;
    font-size: 1.05rem;
    line-height: 1.75;
}

.authors a {
    color: var(--blue);
    text-decoration: none;
}

.authors a:hover {
    text-decoration: underline;
}

.affiliations {
    margin-top: 14px;
    color: var(--muted);
    font-size: 0.98rem;
}

.affiliations p {
    margin: 2px 0;
}

.notes {
    margin-top: 8px !important;
    font-size: 0.92rem;
    font-style: italic;
}

.link-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-top: 24px;
}

.button {
    min-width: 128px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 10px 18px;
    background: var(--paper);
    color: var(--ink);
    font-weight: 700;
    text-decoration: none;
    transition: background-color 160ms ease, border-color 160ms ease, color 160ms ease;
}

.button:hover {
    background: var(--light);
    border-color: #c2cede;
}

.button.primary {
    background: var(--blue);
    border-color: var(--blue);
    color: #fff;
}

.button.primary:hover {
    background: var(--blue-dark);
}

.button.dark {
    background: #243142;
    border-color: #243142;
    color: #fff;
}

.button.dark:hover {
    background: #111827;
}

.teaser-section {
    margin-top: 8px;
}

.section {
    margin-top: 64px;
}

.section-heading {
    max-width: 820px;
    margin: 0 auto 22px;
    text-align: center;
}

.section-heading.compact {
    max-width: 760px;
}

.section-heading p,
.paper-figure figcaption,
.dataset-note,
.table-note {
    color: var(--muted);
}

.section-title {
    margin: 0 0 12px;
    color: var(--ink);
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(1.75rem, 3vw, 2.35rem);
    line-height: 1.18;
    letter-spacing: 0;
    text-align: center;
}

.section-title.align-left {
    text-align: left;
}

.paper-figure {
    margin: 0;
}

.paper-figure img,
.paper-figure video,
.method-card img,
.method-card video,
.comparison-grid video,
.video-pair video {
    width: 100%;
    height: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.paper-figure figcaption {
    max-width: 900px;
    margin: 10px auto 0;
    text-align: center;
    font-size: 0.95rem;
}

.claim-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-top: 34px;
}

.claim-strip article,
.small-metrics div {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.claim-strip article {
    padding: 18px;
    border-top: 4px solid var(--blue);
}

.claim-strip article:nth-child(2) {
    border-top-color: var(--teal);
}

.claim-strip article:nth-child(3) {
    border-top-color: var(--orange);
}

.claim-strip span,
.eyebrow {
    color: var(--blue);
    font-size: 0.78rem;
    font-weight: 780;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.claim-strip h2 {
    margin: 6px 0 8px;
    font-size: 1.08rem;
    line-height: 1.28;
}

.claim-strip p,
.method-card p,
.results p,
.two-column p {
    margin: 0;
    color: var(--muted);
}

.abstract {
    margin: 0 auto;
    padding: 24px 28px;
    border-left: 4px solid var(--blue);
    background: var(--light);
    color: #344056;
    font-size: 1.06rem;
}

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

.motivation-grid article {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 18px;
    background: var(--paper);
}

.motivation-grid article:nth-child(2) {
    border-top: 4px solid var(--teal);
}

.motivation-grid h3 {
    margin: 6px 0 8px;
    font-size: 1.1rem;
    line-height: 1.3;
}

.motivation-grid p {
    margin: 0;
    color: var(--muted);
}

.method-cards {
    display: grid;
    gap: 26px;
}

.method-card {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 26px;
    align-items: center;
    padding-bottom: 26px;
    border-bottom: 1px solid var(--line);
}

.method-card.reverse {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
}

.method-card.reverse div {
    order: 2;
}

.method-card h3 {
    margin: 6px 0 10px;
    font-size: clamp(1.35rem, 2.5vw, 1.8rem);
    line-height: 1.22;
    letter-spacing: 0;
}

.method-card img,
.method-card video {
    height: auto;
}

.method-card video {
    width: 100%;
    margin-right: auto;
    margin-left: auto;
}

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

.benchmark-panel {
    min-width: 0;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 16px;
    background: var(--paper);
}

.benchmark-panel h3 {
    margin: 0 0 12px;
    color: var(--ink);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.5rem;
    text-align: center;
}

.benchmark-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    margin-bottom: 14px;
}

.benchmark-metrics span {
    border-top: 3px solid var(--blue);
    padding-top: 7px;
    color: var(--muted);
    font-size: 0.7rem;
    line-height: 1.25;
    text-align: center;
}

.benchmark-metrics span:nth-child(2) {
    border-top-color: var(--teal);
}

.benchmark-metrics span:nth-child(3) {
    border-top-color: var(--orange);
}

.benchmark-metrics span:nth-child(4) {
    border-top-color: #5a56a6;
}

.benchmark-metrics strong {
    display: block;
    color: var(--ink);
    font-size: 1.22rem;
    font-weight: 800;
    line-height: 1.15;
}

.table-wrap {
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 780px;
    font-size: 0.96rem;
}

.benchmark-table {
    min-width: 0;
    table-layout: fixed;
    font-size: 0.64rem;
}

.benchmark-table th,
.benchmark-table td {
    padding: 6px 3px;
    text-align: center;
}

.benchmark-table th:first-child,
.benchmark-table td:first-child {
    width: 24%;
    text-align: left;
}

.benchmark-table thead th[colspan] {
    text-align: center;
}

.benchmark-table thead tr:nth-child(2) th:first-child {
    text-align: center;
}

th,
td {
    padding: 10px 12px;
    border-bottom: 1px solid var(--line);
    text-align: right;
    white-space: nowrap;
}

th:first-child,
td:first-child {
    text-align: left;
}

thead th {
    background: var(--light);
    color: #243142;
    font-weight: 780;
}

tbody tr:last-child td {
    border-bottom: 0;
}

.ours td {
    background: #eef6ff;
    color: #102a4d;
    font-weight: 800;
}

.table-note {
    margin: 10px 0 0;
    text-align: center;
    font-size: 0.9rem;
}

.qualitative-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    align-items: start;
}

.qualitative-figure h3 {
    margin: 0 0 10px;
    color: var(--ink);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.45rem;
    text-align: center;
}

.two-column {
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    gap: 30px;
    align-items: center;
}

.small-metrics {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.35fr);
    gap: 10px;
    margin-top: 20px;
}

.small-metrics div {
    padding: 10px 8px;
}

.small-metrics strong {
    display: block;
    color: var(--blue);
    font-size: 1rem;
    white-space: nowrap;
}

.small-metrics span {
    display: block;
    color: var(--muted);
    font-size: 0.82rem;
}

.video-pair {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.video-pair figure,
.comparison-grid figure,
.proprietary-grid figure {
    margin: 0;
}

.video-pair video,
.comparison-grid video {
    aspect-ratio: 41 / 46;
    object-fit: cover;
}

.video-pair figcaption,
.comparison-grid figcaption {
    margin-top: 8px;
    color: #344056;
    font-weight: 700;
    text-align: center;
}

.comparison-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.proprietary-grid {
    display: grid;
    grid-template-columns: max-content max-content;
    gap: 20px;
    align-items: center;
    justify-content: center;
}

.proprietary-grid .paper-figure {
    height: 100%;
}

.proprietary-grid .paper-figure img {
    width: auto;
    max-width: none;
    height: 520px;
}

.dataset-note {
    max-width: 820px;
    margin: 18px auto 0;
    text-align: center;
}

.citation pre {
    overflow-x: auto;
    margin: 0;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f4f6f8;
    color: #1f2937;
    font-size: 0.9rem;
    line-height: 1.55;
}

@media (max-width: 860px) {
    .claim-strip,
    .motivation-grid,
    .comparison-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .benchmark-grid {
        grid-template-columns: 1fr;
    }

    .qualitative-grid {
        grid-template-columns: 1fr;
    }

    .method-card,
    .method-card.reverse,
    .two-column,
    .proprietary-grid {
        grid-template-columns: 1fr;
    }

    .proprietary-grid {
        justify-content: stretch;
    }

    .method-card.reverse div {
        order: 0;
    }

    .section-title.align-left {
        text-align: center;
    }
}

@media (max-width: 620px) {
    .page-shell {
        width: min(100% - 22px, 1120px);
        padding-top: 30px;
    }

    .hero {
        padding-bottom: 14px;
    }

    .venue {
        font-size: 1.12rem;
    }

    .authors,
    .affiliations {
        font-size: 0.92rem;
    }

    .button {
        width: 100%;
        min-width: 0;
    }

    .claim-strip,
    .motivation-grid,
    .small-metrics,
    .video-pair,
    .comparison-grid {
        grid-template-columns: 1fr;
    }

    .section {
        margin-top: 46px;
    }

    .abstract {
        padding: 18px;
        font-size: 1rem;
    }

    .method-card {
        gap: 16px;
        padding-bottom: 22px;
    }

    .benchmark-panel {
        padding: 12px;
    }

    .benchmark-table {
        font-size: 0.58rem;
    }

    .benchmark-table th,
    .benchmark-table td {
        padding: 5px 2px;
    }

    .proprietary-grid .paper-figure img {
        width: 100%;
        max-width: 100%;
        height: auto;
    }

}
