/* Experience Prompting project page. Base layout: Bulma / Academic Project Page Template. */
/* Noto Sans (SIL Open Font License, static/fonts/OFL.txt), Latin subset, bundled so the page needs no network */
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400 700; font-display: swap; src: url('../fonts/NotoSans-latin-upright.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Noto Sans'; font-style: italic; font-weight: 400; font-display: swap; src: url('../fonts/NotoSans-latin-italic.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
:root {
  --ink: #22262e;
  --muted: #667085;
  --line: #e5e8ef;
  --soft: #f5f6fa;
  /* colours of the paper's Figure 1 labels */
  --query: #fbf3cc;  --query-ink: #7a5a00;
  --exp: #dcf1d5;    --exp-ink: #2c6a28;   --exp-strong: #4c9a45;
  --fut: #d2edfb;    --fut-ink: #135a82;   --fut-strong: #2f8fc4;
  /* left / right object accents in the multi-reference tab */
  --l1: #4f7df9; --l2: #31c6b0; --l-bg: #eef3ff; --l-line: #cfdcff;
  --r1: #f5923e; --r2: #f25f8b; --r-bg: #fff3e8; --r-line: #ffd9b8;
  --shadow: 0 22px 60px -28px rgba(30, 41, 80, .28);
  --radius: 22px;
  /* width unit: 1px on windows up to ~1180px, growing to 1.5px from ~1765px on; every content width is a multiple of it */
  --u: clamp(1px, .085vw, 1.5px);
  --wide: calc(1060 * var(--u));  /* teaser, generalization examples, demo card */
  --fig: calc(var(--wide) * .826);  /* flow charts, as wide as the content of the demo card */
  --mid: calc(840 * var(--u));    /* figures, comparisons, training data, running text */
  --text: calc(10px + 6 * var(--u));
}
html { scroll-behavior: smooth; }
body { font-family: 'Noto Sans', -apple-system, 'Segoe UI', Roboto, sans-serif; color: var(--ink); }
.publication-title, .publication-authors, .teaser { font-family: 'Noto Sans', sans-serif; }
.publication-title { letter-spacing: -.01em; text-wrap: balance; font-size: clamp(1.65rem, 3.5vw, 2.6rem) !important; line-height: 1.22; }
.publication-links { margin-top: 1.1rem; }
.publication-authors { line-height: 1.6; }
.publication-authors .author-block { display: inline-block; margin: 0 .12em; white-space: nowrap; }
.publication-authors a, .publication-authors .author-name { color: hsl(204, 86%, 53%); }  /* link blue of the Academic Project Page Template */
.publication-authors a:hover { text-decoration: underline; }
.publication-authors.affiliations { margin-top: .35rem; color: var(--ink); }
.publication-authors.affiliations .author-block { margin: 0 .5em; }
.button.is-soon { cursor: default; opacity: .8; }
.button.is-soon:hover { background-color: #363636; }
.button .soon { margin-left: .5em; padding: 1px 7px; border-radius: 999px; background: rgba(255, 255, 255, .18); font-size: .68em; font-weight: 600; letter-spacing: .02em; }
.link-block { display: inline-block; margin: 4px 3px; }
.button .icon svg { width: 1.05em; height: 1.05em; }
.tldr-section { padding: 8px 1.5rem 0; }
.tldr { padding: 1.25rem 1.5rem !important; background: #f5f6f9 !important; border: 1px solid #dde1ea; border-radius: 14px; font-size: calc(var(--text) * 1.1); line-height: 1.55; }
.hero.teaser { padding: 2.4rem 1.25rem 1rem; }
.hero.teaser > .container { width: 100%; max-width: max(1152px, var(--wide)); }
.tldr-section > .container, .section.hero.is-light > .container { width: 100%; max-width: calc(960 * var(--u)); }
.section.hero.is-light .content { font-size: var(--text); }
.teaser .title.is-3 { margin-bottom: 1.1rem; }
.gen-title { font-size: 1.5rem !important; color: #3779a8 !important; font-weight: 600 !important; margin: 1.9rem 0 .8rem !important; }
.lead { max-width: var(--mid); margin: 0 auto 1.6rem !important; font-size: var(--text) !important; line-height: 1.6; color: #444b59; text-wrap: pretty; }
.lead.small { font-size: calc(var(--text) * .92) !important; color: var(--muted); margin-top: 1.4rem !important; }

/* media slots: images now, videos later (see main.js) */
.media img, .media video { display: block; width: 100%; height: auto; margin: 0 auto; }
.media video { border-radius: 12px; }
.section.hero.is-light { background: #f7f8fb; }

/* ---------------------------------------------------------------- teaser (Figure 1): robot -> query -> two cases
 * Desktop: a 100 x 41 design grid, every child is placed by --x / --y / --w in those units, so it scales as one piece.
 * The diagonal arrows are exactly 45 degrees. Narrow screens: a vertical two-column layout. */
.flow { position: relative; width: min(100%, var(--fig)); margin: 1rem auto 0; aspect-ratio: 100 / 41; container-type: inline-size; text-align: center; --rigid: #2f6fd0; --def: #e8702a; }
.flow > *, .f-case > * { position: absolute; left: calc(var(--x) * 1%); top: calc(var(--y) / 41 * 100%); width: calc(var(--w) * 1%); margin: 0; }
.f-case { display: contents; }
.flow figure { position: absolute; }
.flow .media { border-radius: 10px; overflow: hidden; box-shadow: 0 10px 28px -14px rgba(30, 41, 80, .55); background: #eceef3; }
.flow .media img, .flow .media video { aspect-ratio: 832 / 480; object-fit: cover; border-radius: 0; }
.f-robot { --x: 0; --y: 5.2; --w: 16; height: calc(26 / 41 * 100%); }
.f-bubble { position: absolute; left: 0; right: 0; bottom: calc(15.4 / 26 * 100%); background: #fff; border: 2px solid #232a3a; border-radius: 1.5cqw; padding: .95cqw 1.1cqw; color: #b3261e; font-weight: 600; font-size: clamp(10.5px, 1.62cqw, 21px); line-height: 1.3; box-shadow: 0 8px 22px -14px rgba(30, 41, 80, .6); }
.f-dot { position: absolute; border: 2px solid #232a3a; background: #fff; border-radius: 50%; }
/* thought bubbles: they leave the robot's head small, rise and grow until they reach the question; the question itself is still */
.f-dot { left: 49%; top: calc(10.9 / 26 * 100%); width: 1.4cqw; height: 1.4cqw; transform: translateX(-50%); animation: bubble-rise 3.6s linear infinite both; }
.f-dot.d2 { animation-delay: 1.2s; } .f-dot.d3 { animation-delay: 2.4s; }
@keyframes bubble-rise {
  0% { width: .3cqw; height: .3cqw; transform: translate(-50%, 4.3cqw); opacity: 0; }
  10% { opacity: 1; }
  33% { transform: translate(calc(-50% + .3cqw), 2.95cqw); }
  66% { transform: translate(calc(-50% - .2cqw), 1.5cqw); }
  88% { opacity: 1; }
  100% { width: 1.4cqw; height: 1.4cqw; transform: translate(-50%, 0); opacity: 0; }
}
.f-bot { position: absolute; left: 18%; bottom: 0; width: 62%; -webkit-mask-image: linear-gradient(#000 80%, transparent); mask-image: linear-gradient(#000 80%, transparent); }
.f-query { --x: 17.4; --y: 13.58; --w: 22; }
.f-prompt { --x: 16.9; --y: 28.6; --w: 23; font-size: max(9px, 1.36cqw); line-height: 1.4; color: #3c4353; text-wrap: balance; }
.f-pill { position: absolute; left: 50%; bottom: 0; transform: translate(-50%, 50%); white-space: nowrap; font-weight: 700; font-size: clamp(9.5px, 1.5cqw, 18px); padding: .25cqw 1.2cqw; border-radius: 999px; line-height: 1.45; box-shadow: 0 2px 8px rgba(20, 28, 60, .16); }
.f-arrows { --x: 0; --y: 0; --w: 100; height: 100%; left: 0; top: 0; pointer-events: none; overflow: visible; }
.f-arrows-sm, .f-down { display: none; }
.c-rigid .f-title { --x: 51; --y: -.6; --w: 49; } .c-def .f-title { --x: 51; --y: 21.4; --w: 49; }
.c-rigid .f-exp { --x: 51; --y: 2.85; --w: 21.2; } .c-rigid .f-fut { --x: 78.8; --y: 2.85; --w: 21.2; }
.c-def .f-exp { --x: 51; --y: 24.85; --w: 21.2; } .c-def .f-fut { --x: 78.8; --y: 24.85; --w: 21.2; }
.f-title { font-weight: 700; font-size: clamp(11px, 1.75cqw, 22px); line-height: 1.3; color: #22262e; }
.f-title b { font-weight: 800; } .c-rigid .f-title b { color: var(--rigid); } .c-def .f-title b { color: var(--def); }

@media (max-width: 768px) {
  .flow { aspect-ratio: auto; display: grid; grid-template-columns: 1fr 1fr; gap: 22px 12px; align-items: start; width: 100%; }
  .flow > *, .f-case > * { position: static; left: auto; top: auto; width: auto; }
  .flow figure { position: relative; }
  .f-robot { grid-column: 1 / -1; position: relative; display: flex; align-items: center; justify-content: center; gap: 14px; height: auto; }
  .f-bubble { position: static; max-width: 210px; border-radius: 16px; padding: 10px 14px; font-size: 14px; }
  .f-dot { display: none; }
  .f-bot { position: static; width: 84px; }
  .f-query { grid-column: 1 / -1; width: min(78%, 330px) !important; margin: 0 auto !important; }
  .f-prompt { grid-column: 1 / -1; width: min(92%, 340px) !important; margin: 0 auto !important; font-size: 13.5px; }
  .f-arrows { display: none; }
  .f-arrows-sm { display: block; grid-column: 1 / -1; width: 100%; margin-top: 4px !important; }
  .f-case { display: grid; gap: 16px; justify-items: center; }
  .f-case.c-rigid { grid-column: 1; } .f-case.c-def { grid-column: 2; }
  .f-case > figure { width: 100%; }
  .f-title { font-size: 14px; min-height: 2.6em; }
  .f-pill { font-size: 11px; padding: 1px 9px; }
  .f-down { display: block; width: 22px; fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; margin: 6px 0 -4px; }
  .c-rigid .f-down { stroke: var(--rigid); } .c-def .f-down { stroke: var(--def); }
}

/* ---------------------------------------------------------------- start frame + reference -> target, and method comparisons */
.icon-defs { position: absolute; }
.eq, .cmp { --ip: calc(22 * var(--u)); --ia: calc(15 * var(--u)); }
.ic-plus { width: var(--ip); height: var(--ip); justify-self: center; align-self: center; flex: none; background: #fff; border-radius: 50%; box-shadow: 0 3px 10px -3px rgba(30, 41, 80, .4), inset 0 0 0 1px var(--line); }
.ic-arrow { width: calc(36 * var(--u)); height: var(--ia); justify-self: center; align-self: center; flex: none; }
.eq .media, .slot .media { border-radius: calc(8 * var(--u)); overflow: hidden; background: #eceef3; box-shadow: 0 6px 16px -9px rgba(30, 41, 80, .55); }
.eq .media img, .eq .media video, .slot .media img, .slot .media video { aspect-ratio: 832 / 480; object-fit: cover; border-radius: 0; }

/* two examples side by side; in each one the start frame on the left is shared by both rows */
.gen-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: calc(22 * var(--u)) calc(30 * var(--u)); max-width: var(--wide); margin: 0 auto; }
.eq { --n: 1; --fan: calc(24 * var(--u)); --plus: calc(30 * var(--u)); --arr: calc(44 * var(--u)); --s: calc((100% - var(--fan) - var(--n) * var(--plus) - var(--arr)) / (var(--n) + 2)); display: grid; grid-template-columns: var(--s) var(--fan) minmax(0, 1fr); align-items: center; padding: calc(14 * var(--u)); border: 1px solid var(--line); border-radius: 16px; background: #fcfcfe; }
.eq-2ref { --n: 2; --fan: calc(20 * var(--u)); --plus: calc(26 * var(--u)); --arr: calc(40 * var(--u)); }
.eq-2ref .media img, .eq-2ref .media video { aspect-ratio: 624 / 480; }
.eq-2ref .media video { object-position: var(--pos-x, 50%) 50%; }
.eq-fan { width: 100%; height: 100%; align-self: stretch; fill: none; stroke: #a9b8dc; stroke-width: 1.8; overflow: visible; }
.eq-fan path { vector-effect: non-scaling-stroke; stroke-linecap: round; }
.eq-rows { display: grid; gap: calc(12 * var(--u)); }
.eq-row { display: grid; grid-template-columns: var(--plus) minmax(0, 1fr) var(--arr) minmax(0, 1fr); align-items: center; }
.eq-2ref .eq-row { grid-template-columns: var(--plus) minmax(0, 1fr) var(--plus) minmax(0, 1fr) var(--arr) minmax(0, 1fr); }

/* inputs -> ours on top, the other methods below */
.cmp { container-type: inline-size; max-width: var(--mid); margin: 0 auto; }
.cmp-top, .cmp-rest { --slot: 19.5cqw; }
.slot { width: var(--slot); margin: 0; }
.slot figcaption { font-size: calc(var(--text) * .82); font-weight: 600; color: #4a5160; line-height: 1.3; margin-top: 6px; }
.cmp-top, .cmp-rest { display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-start; }
.cmp-top { gap: calc(8 * var(--u)); padding: calc(14 * var(--u)) 12px calc(10 * var(--u)); border-radius: 16px; background: #f3faf1; border: 1px solid #d9ecd5; }
.cmp-top .ic-plus, .cmp-top .ic-arrow { align-self: flex-start; }
.cmp-top .ic-plus { margin-top: calc(var(--slot) * 240 / 832 - var(--ip) / 2); }
.cmp-top .ic-arrow { margin-top: calc(var(--slot) * 240 / 832 - var(--ia) / 2); }
.slot.is-ours .media { box-shadow: 0 0 0 2.5px var(--exp-strong), 0 8px 20px -9px rgba(44, 106, 40, .6); }
.slot.is-ours figcaption { color: var(--exp-ink); font-weight: 700; }
.cmp-rest { gap: calc(14 * var(--u)) calc(16 * var(--u)); padding: calc(14 * var(--u)) 12px calc(10 * var(--u)); margin-top: calc(12 * var(--u)); border-radius: 16px; background: #faf4f4; border: 1px solid #efdfdf; }
.cmp-rest .slot figcaption { color: #a23b3b; }
/* baselines have other output sizes; the paper shows them at the common shape */
.cmp .media img, .cmp .media video { object-fit: fill; }

/* training data: one card per property, two interactions each */
.train { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: calc(16 * var(--u)); max-width: var(--mid); margin: 1.2rem auto 0; }
.train-card { --c: #2f6fd0; border: 1px solid var(--line); border-top: 3px solid var(--c); border-radius: 14px; background: #fcfcfe; padding: 10px 14px 10px; }
.train-card h4 { font-weight: 700; font-size: var(--text); color: var(--c); margin-bottom: 8px; }
.train-card h4 span { font-weight: 500; font-size: .8em; color: var(--muted); margin-left: 4px; }
.train-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.train-pair .slot { width: 100%; }
.t-deformable { --c: #e8702a; } .t-brittle { --c: #b23a5c; } .t-two { --c: #178a78; }

@media (max-width: 768px) {
  .gen-pair { grid-template-columns: minmax(0, 1fr); }
  .eq { grid-template-columns: minmax(0, 1fr); gap: 12px; padding: 12px; --plus: 28px; --arr: 38px; }
  .eq-2ref { --plus: 24px; --arr: 30px; }
  .eq-start { width: 48%; margin: 0 auto; }
  .eq-fan { display: none; }
  .eq .ic-plus { width: 20px; height: 20px; } .eq-2ref .ic-arrow { width: 26px; }
  .train { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 768px) {  /* inputs in a row, then a downward arrow and our result */
  .cmp-top, .cmp-rest { --slot: 25cqw; }
  .cmp-rest { --slot: 40cqw; }
  .cmp-top { gap: 8px 4px; } .cmp-top .ic-plus { width: 18px; height: 18px; margin-top: calc(var(--slot) * 240 / 832 - 9px); }
  .cmp-top .ic-arrow { width: 34px; margin: 6px calc(50% - 17px); transform: rotate(90deg); }
  .cmp-top .slot.is-ours { --slot: 50cqw; }
}

/* ---------------------------------------------------------------- demo card */
.demo-intro { margin-bottom: 1.4rem; }
.demo-card { max-width: calc(var(--wide) * .881); margin: 0 auto; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(16px, 2.8vw, 36px); }
.tabs-row { display: flex; justify-content: center; margin-bottom: .4rem; }
.cmp-tabs { margin-bottom: 1.2rem; }
.seg { display: inline-flex; background: var(--soft); border-radius: 999px; padding: 5px; gap: 4px; box-shadow: inset 0 0 0 1px var(--line); }
.seg-btn { font: inherit; font-weight: 600; font-size: .98rem; border: 0; background: none; color: var(--muted); padding: 10px 26px; border-radius: 999px; cursor: pointer; transition: color .18s, background .2s, box-shadow .2s; }
.seg-btn:hover { color: var(--ink); }
.seg-btn.is-active { background: #fff; color: var(--ink); box-shadow: 0 4px 14px -4px rgba(30, 41, 80, .28); }
.seg-btn:focus-visible, .icon-btn:focus-visible, .ref-card:focus-visible, .sample:focus-visible, .copy-btn:focus-visible { outline: 3px solid var(--l1); outline-offset: 2px; }

.step { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; margin: 1.9rem 0 1rem; }
.step .num { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: .95rem; color: #fff; background: #2b3242; flex: none; }
.pill { font-weight: 700; padding: 4px 16px; border-radius: 999px; font-size: 1.02rem; }
.pill-query { background: var(--query); color: var(--query-ink); }
.pill-exp { background: var(--exp); color: var(--exp-ink); }
.pill-fut { background: var(--fut); color: var(--fut-ink); }
.step .hint { color: var(--muted); font-size: .95rem; }

/* ------------------------------------------------- query thumbnails (both tabs) */
.icons { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 12px; padding: 4px; }
.icon-btn { font-family: inherit; position: relative; padding: 0; border: 0; border-radius: 16px; aspect-ratio: 141 / 100; cursor: pointer; background: transparent; transition: transform .2s cubic-bezier(.2, .8, .3, 1.2), filter .25s, opacity .25s, box-shadow .2s; }
.icon-btn .pic { transition: opacity .25s, filter .25s; position: absolute; inset: 0; border-radius: 16px; overflow: hidden; background: #eceef3; box-shadow: 0 1px 2px rgba(20, 28, 60, .1); }
.icon-btn img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .35s; }
.icon-btn .lbl { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 4px 5px; font-size: 11px; line-height: 1.15; font-weight: 600; color: #fff; text-align: center; background: linear-gradient(to top, rgba(12, 16, 28, .78), rgba(12, 16, 28, 0)); opacity: 0; transition: opacity .2s; }
.icon-btn:hover { transform: translateY(-3px); }
.icon-btn:hover img { transform: scale(1.07); }
.icon-btn:hover .lbl, .icon-btn.sel .lbl, .icon-btn:focus-visible .lbl { opacity: 1; }
/* selected: gradient border, soft glow, check badge */
.icon-btn.sel { transform: scale(1.04); z-index: 2; }
.icon-btn.sel::before { content: ""; position: absolute; inset: -5px; border-radius: 20px; background: linear-gradient(135deg, var(--c1, #4f7df9), var(--c2, #31c6b0)); box-shadow: 0 10px 26px -8px color-mix(in srgb, var(--c1, #4f7df9) 70%, transparent); }
.icon-btn.sel .pic { inset: 0; box-shadow: 0 0 0 2.5px #fff; }
.icon-btn .badge { position: absolute; top: -9px; right: -9px; width: 24px; height: 24px; border-radius: 50%; background: linear-gradient(135deg, var(--c1, #4f7df9), var(--c2, #31c6b0)); color: #fff; display: none; place-items: center; box-shadow: 0 0 0 2.5px #fff; z-index: 3; }
.icon-btn .badge svg { width: 14px; height: 14px; }
.icon-btn.sel .badge { display: grid; }
/* ------------------------------------------------- reference cards */
.refs { display: flex; flex-wrap: wrap; justify-content: center; gap: 18px; }
.ref-card { font-family: inherit; position: relative; flex: 0 1 min(calc(140px + 160 * var(--u)), calc((100% - 36px) / 3)); min-width: 190px; padding: 0; border: 3px solid transparent; border-radius: 18px; background: #f2f4f8; overflow: hidden; cursor: pointer; transition: filter .25s, opacity .25s, box-shadow .25s, border-color .2s, transform .2s; }
.ref-card video { width: 100%; aspect-ratio: 832 / 480; display: block; object-fit: cover; background: #e9ebf1; }
.ref-card { container-type: inline-size; }
/* sized with the card and tight in the corner, so it stays clear of the objects */
.ref-card .tag { position: absolute; left: 2px; bottom: 2px; padding: 0 .42em; height: auto; border-radius: 999px; font-weight: 700; font-size: clamp(10.5px, 3.9cqw, 15px); line-height: 1.3; background: rgba(255, 255, 255, .92); color: #2d3442; box-shadow: 0 2px 8px rgba(20, 28, 60, .22); }
.ref-card.is-off { opacity: .68; filter: grayscale(.45); }
.ref-card.is-off:hover { opacity: .95; filter: none; transform: translateY(-2px); }
.ref-card .tag { z-index: 1; }
@media (min-width: 769px) { .side .ref-card .tag { font-size: clamp(10px, 4.4cqw, 15px); } }
.ref-card.is-on { border-color: var(--exp-strong); box-shadow: 0 14px 34px -16px rgba(44, 106, 40, .55); }
.ref-card.is-on .tag { background: var(--exp); color: var(--exp-ink); }
.side .ref-card.is-on { border-color: var(--acc); box-shadow: 0 14px 30px -16px color-mix(in srgb, var(--acc) 70%, transparent); }
.side .ref-card.is-on .tag { background: #fff; color: var(--acc-ink); }

/* ------------------------------------------------- target */
.target { max-width: calc(340px + 200 * var(--u)); margin: 0 auto; }
.target-frame { border-radius: 20px; overflow: hidden; background: #eceef3; box-shadow: 0 24px 60px -26px rgba(19, 90, 130, .45); border: 3px solid var(--fut); }
.target-frame video { width: 100%; aspect-ratio: 832 / 480; display: block; object-fit: cover; }
.target-cap { text-align: center; margin: 14px auto 4px; font-size: 1.04rem; color: #3c4353; line-height: 1.5; }
.samples { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; margin-top: 8px; min-height: 32px; }
.sample { font: inherit; font-size: .85rem; font-weight: 600; padding: 5px 15px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--muted); cursor: pointer; transition: all .18s; }
.sample:hover { border-color: var(--fut-strong); color: var(--fut-ink); }
.sample.is-on { background: var(--fut); border-color: var(--fut-strong); color: var(--fut-ink); }

/* ------------------------------------------------- multi-reference pair */
.pair { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: stretch; gap: 14px; }
.side { border-radius: 20px; padding: 16px; min-width: 0; min-height: calc(50px + 160 * var(--u)); border: 1.5px solid var(--bd); background: var(--bg); transition: background .25s, border-color .25s; display: flex; flex-direction: column; }
.side-left { --bg: var(--l-bg); --bd: var(--l-line); --acc: var(--l1); --acc-ink: #2149b8; }
.side-right { --bg: var(--r-bg); --bd: var(--r-line); --acc: var(--r1); --acc-ink: #b4580b; }
.side-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; font-weight: 700; font-size: 1.06rem; }
.side-head img { width: 46px; height: 46px; border-radius: 12px; object-fit: cover; box-shadow: 0 0 0 2.5px #fff, 0 0 0 4.5px var(--acc); }
.side .refs { flex: 1; align-content: center; gap: 12px; }
.side .ref-card { flex: 1 1 150px; min-width: 130px; max-width: calc(140px + 160 * var(--u)); }
.plus { align-self: center; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-size: 26px; font-weight: 300; color: #6b7386; background: #fff; box-shadow: 0 6px 18px -6px rgba(30, 41, 80, .35), inset 0 0 0 1px var(--line); }
#m-target-wrap { animation: rise .45s cubic-bezier(.2, .8, .3, 1); }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* ------------------------------------------------- bibtex */
.bib-wrap { position: relative; }
.bib-wrap pre { border-radius: 14px; padding: 1.1rem 1.25rem; background: #f5f6f9; }
.copy-btn { position: absolute; right: 12px; top: 12px; font: inherit; font-size: .85rem; border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 5px 15px; cursor: pointer; color: var(--muted); }
.copy-btn:hover { color: var(--ink); border-color: #c4cbd9; }

/* ------------------------------------------------- responsive */
@media (max-width: 768px) {
  .hero.teaser { padding: 1.6rem .75rem .5rem; }
  .icons { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; }
  .icon-btn { aspect-ratio: 832 / 480; }
  .ref-card { flex: 0 1 calc(50% - 9px); min-width: 0; }
  .ref-card .tag { position: static; display: block; font-size: .72rem; padding: 3px 4px; border-radius: 0; box-shadow: none; }
  .teaser .columns.is-variable { --columnGap: .75rem; margin-left: 0; margin-right: 0; }
  .pair { grid-template-columns: minmax(0, 1fr); }
  .plus { justify-self: center; transform: none; margin: -6px 0; }
  .seg { width: 100%; } .seg-btn { flex: 1; padding: 9px 8px; font-size: .9rem; white-space: nowrap; }
  .side .ref-card { flex: 1 1 calc(50% - 6px); min-width: 0; }
  .side { min-height: 0; padding: 12px; }
}
@media (prefers-reduced-motion: reduce) { .icon-btn, .icon-btn img, .ref-card { transition: none; } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .flow-in { display: none; }
  .f-dot, .f-dot.d2, .f-dot.d3, #m-target-wrap { animation: none; }
  .f-dot.d2 { width: 1.1cqw; height: 1.1cqw; top: calc(13 / 26 * 100%); } .f-dot.d3 { width: .6cqw; height: .6cqw; top: calc(14.4 / 26 * 100%); }
}

/* ---------------------------------------------------------------- robot planning flow chart (Figure 4), drawn in main.js
 * Desktop: a 100 x --H design grid, every child is placed by --x / --y / --w / --h in those units, like the teaser.
 * Narrow screens: inputs, then the two plans side by side, then execution. */
.rp-panel { padding-top: 1.1rem; }
.rp { position: relative; width: min(100%, var(--fig)); margin: 0 auto; aspect-ratio: 100 / var(--H); container-type: inline-size; text-align: center; }
.rp > *, .rp-plan > *, .rp-exec-part > * { position: absolute; left: calc(var(--x) * 1%); top: calc(var(--y) / var(--H) * 100%); width: calc(var(--w) * 1%); margin: 0; }
.rp-plan, .rp-exec-part { display: contents; }
.rp figure { position: absolute; }
.rp .media { border-radius: 10px; overflow: hidden; box-shadow: 0 10px 28px -14px rgba(30, 41, 80, .55); background: #eceef3; }
.rp .media img, .rp .media video { aspect-ratio: 832 / 480; object-fit: cover; border-radius: 0; }
.rp .rp-exec .media video { aspect-ratio: 480 / 270; }
.rp .f-pill { font-size: max(8.5px, 1.3cqw); padding: .2cqw 1cqw; }
.rp-pill-exec { background: #fbe6bd; color: #7a4f00; }
.rp-speed { position: absolute; right: max(6px, .7cqw); top: max(6px, .7cqw); padding: 0 max(6px, .7cqw); border-radius: 999px; background: rgba(255, 255, 255, .92); color: #22262e; font-weight: 700; font-size: max(9px, 1.3cqw); line-height: 1.55; }
.rp-arrows { --x: 0; --y: 0; --w: 100; height: 100%; pointer-events: none; overflow: visible; }
.rp .rp-down { display: none; }
.rp-prompt { font-size: max(9px, 1.36cqw); line-height: 1.35; color: #3c4353; text-wrap: balance; }
.rp-prompt.is-above { transform: translateY(-100%); }
.rp-prompt .word { color: var(--c-ink); }
.rp-box { height: calc(var(--h) / var(--H) * 100%); display: flex; align-items: center; justify-content: center; background: #fbe7dc; border: 2px solid #d9a88c; border-radius: 1.2cqw; font-weight: 600; font-size: max(9.5px, 1.5cqw); line-height: 1.3; color: #22262e; }
.rp-res { display: flex; flex-direction: column; align-items: center; gap: .5cqw; font-size: max(9.5px, 1.5cqw); line-height: 1.25; color: var(--c-res); }
.rp-face { width: 4.2cqw; height: 4.2cqw; }
.rp-idm { background: #fdf2d9; border-color: #e3bf6d; font-size: max(9px, 1.4cqw); }
.rp-seed { width: min(100%, var(--fig)); margin: 0 auto .8rem !important; padding-bottom: .3rem; border-bottom: 1px solid var(--line); text-align: left; font-weight: 700; font-size: var(--text); color: #444b59; }
@media (min-width: 769px) { .rp-panel .rp ~ .rp-seed { margin-top: calc(var(--text) * -1.35) !important; } }  /* the tie arrow ends on this line */
.rp-tie-text { color: #2f74bd; font-weight: 600; font-size: max(9px, 1.4cqw); line-height: 1.35; }
.rp-tie { display: none; align-items: center; justify-content: center; gap: 12px; margin: .4rem auto .6rem; color: #2f74bd; font-weight: 600; font-size: var(--text); }
.rp-tie-arrow { width: calc(24 * var(--u)); flex: none; overflow: visible; }

@media (max-width: 768px) {
  .rp { aspect-ratio: auto; display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px 10px; align-items: start; width: 100%; }
  .rp > *, .rp-plan > *, .rp-exec-part > * { position: static; left: auto; top: auto; width: auto; }
  .rp-box { height: auto; }
  .rp figure { position: relative; width: 100%; }
  .rp-arrows { display: none; }
  .rp-in { grid-column: span 2; margin-bottom: 10px !important; }
  .rp .f-pill { font-size: 11px; padding: 1px 9px; }
  .rp .rp-in .f-pill { font-size: 9px; padding: 1px 6px; }
  .rp-plan { grid-column: span 3; display: grid; gap: 8px; justify-items: center; padding: 12px 8px; border-radius: 14px; background: color-mix(in srgb, var(--c) 7%, #fff); }
  .rp-prompt.is-above { transform: none; }
  .rp-prompt { font-size: 12.5px; min-height: 4.1em; }
  .rp-box { font-size: 13px; border-radius: 10px; padding: 8px 10px; }
  .rp-fut { margin-bottom: 8px !important; }
  .rp-res { font-size: 13.5px; gap: 4px; }
  .rp-face { width: 34px; height: 34px; }
  .rp .rp-down { display: block; width: 20px; fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke: var(--c); }
  .rp-exec-part { grid-column: 1 / -1; display: grid; gap: 10px; justify-items: center; }
  .rp-exec-part > .rp-exec { max-width: 340px; }
  .rp-speed { font-size: 13px; right: 8px; top: 8px; padding: 0 9px; }
  .rp-tie { display: flex; margin: 1rem auto; }
  .rp-tie-text { display: none; }
  .rb-seg .seg-btn { padding: 9px 2px; font-size: .84rem; }
}
/* end of the robot planning flow chart */
