/* ------------------------------------------------------------------------
   DesignOrbit project page — classic academic layout
   Edit the colour tokens below to re-skin the whole page.
   ------------------------------------------------------------------------ */
:root {
  --accent: #E0218A;          /* DesignOrbit pink: title, links, active tabs, "ours" highlights */
  --accent-strong: #C4177A;   /* hover state of the accent */
  --accent-soft: #FCDDEC;     /* light pink for badges, active nav, focus rings */
  --annot: #5B21B6;           /* violet for artefact annotations (kept distinct from the accent) */
  --ink: #2B1E26;
  --ink-2: #5C4A55;
  --ink-3: #8C7783;
  --line: #F1D7E4;
  --bg: #ffffff;
  --bg-soft: #FFF4F9;         /* light pink section background */
  --card: #ffffff;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(80, 20, 50, .06), 0 1px 3px rgba(80, 20, 50, .10);
  --maxw: 1120px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --frame: 480 / 320;         /* video frame format: 480 wide x 320 high (81 frames, 15 fps) */
}

* { box-sizing: border-box; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
html { scroll-behavior: smooth; scroll-padding-top: 64px; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img, video { display: block; max-width: 100%; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; font-weight: 700; letter-spacing: -.01em; }
h2 { font-size: 1.7rem; margin-top: 0; }
h3 { font-size: 1.15rem; margin-top: 1.6em; }
p { margin: 0 0 1em; }
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
.container.wide { max-width: 1400px; }   /* gallery + baseline comparison: bigger clips */
.narrow { max-width: 820px; margin-left: auto; margin-right: auto; }
.muted { color: var(--ink-3); }
.small { font-size: .9rem; }
.center { text-align: center; }
section { padding: 56px 0; }
section + section { border-top: 1px solid var(--line); }
section.soft { background: var(--bg-soft); }
.section-head { margin-bottom: 22px; }
.section-head p { color: var(--ink-2); max-width: 820px; }

/* ---------- header ---------- */
header.hero { padding: 64px 0 40px; text-align: center; }
header.hero h1 { font-size: 2.6rem; margin-bottom: .35em; }
header.hero h1 .brand { color: var(--accent); }
header.hero .tagline { font-size: 1.2rem; color: var(--ink-2); margin-bottom: 1.2em; }
header.hero .authors { color: var(--ink-2); margin-bottom: .3em; }
header.hero .authors a { color: var(--accent); text-decoration: none; border-bottom: 1px solid transparent; }
header.hero .authors a:hover { color: var(--accent-strong); border-bottom-color: currentColor; }
header.hero .venue { color: var(--ink-3); margin-bottom: 1.4em; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 18px; border-radius: 999px; background: var(--accent); color: #fff;
  font-weight: 600; font-size: .95rem; border: 1px solid transparent; cursor: pointer;
}
.btn:hover { text-decoration: none; background: var(--accent-strong); }
.btn.secondary { background: #fff; color: var(--ink); border-color: var(--line); }
.btn.secondary:hover { background: var(--accent-soft); }
.btn.disabled { opacity: .5; pointer-events: none; }
.btn svg { width: 16px; height: 16px; }

/* ---------- sticky in-page nav ---------- */
nav.topnav {
  position: sticky; top: 0; z-index: 30; background: rgba(255,255,255,.92);
  backdrop-filter: saturate(160%) blur(8px); border-bottom: 1px solid var(--line);
}
nav.topnav .container { display: flex; align-items: center; gap: 4px; height: 48px; overflow-x: auto; }
nav.topnav a { white-space: nowrap; padding: 6px 10px; border-radius: 6px; color: var(--ink-2); font-size: .9rem; font-weight: 500; }
nav.topnav a:hover, nav.topnav a.active { background: var(--accent-soft); color: var(--accent); text-decoration: none; }
nav.topnav .spacer { flex: 1; }

/* ---------- stat chips ---------- */
.stats { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin: 18px 0 8px; }
.stat { flex: 1 1 150px; background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 16px; text-align: center; }
.stat b { display: block; font-size: 1.35rem; color: var(--accent); }
.stat span { font-size: .85rem; color: var(--ink-3); }

/* ---------- video cards ---------- */
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.grid.teaser { grid-template-columns: repeat(3, 1fr); }
.grid.teaser, #gallery .grid { align-items: start; }   /* an opened prompt grows its own card, not the whole row */
figure.vcard { margin: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
figure.vcard.ours { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-soft), var(--shadow); }
.vwrap { position: relative; background: #f3e6ec; aspect-ratio: var(--frame); cursor: pointer; }
.vwrap video { width: 100%; height: 100%; object-fit: cover; }
.vwrap .input-thumb {
  position: absolute; left: 6px; bottom: 6px; width: 24%; border: 2px solid #fff; border-radius: 4px;
  box-shadow: 0 1px 4px rgba(0,0,0,.35); background: #fff; overflow: hidden;
}
.vwrap .input-thumb img { width: 100%; aspect-ratio: var(--frame); object-fit: cover; }
.vwrap .input-thumb::after {
  content: "input"; position: absolute; left: 0; right: 0; bottom: 0; font-size: 9px; line-height: 1.3;
  text-align: center; background: rgba(0,0,0,.55); color: #fff; letter-spacing: .04em; text-transform: uppercase;
}
.vwrap .badge {
  position: absolute; top: 6px; left: 6px; font-size: 11px; font-weight: 600; padding: 2px 7px; border-radius: 999px;
  background: rgba(255,255,255,.9); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.2);
}
.vwrap .badge.ours { background: var(--accent); color: #fff; }
.vwrap .annot {
  position: absolute; right: 6px; bottom: 6px; font-size: 11px; font-weight: 600; padding: 2px 7px; border-radius: 4px;
  background: var(--annot); color: #fff;
}
.vwrap .playhint {
  position: absolute; inset: 0; display: none; align-items: center; justify-content: center; pointer-events: none;
}
.vwrap.paused .playhint { display: flex; }
.vwrap .playhint span { width: 44px; height: 44px; border-radius: 50%; background: rgba(0,0,0,.55); color: #fff; display: grid; place-items: center; font-size: 18px; }
figcaption { padding: 9px 12px 11px; font-size: .88rem; color: var(--ink-2); }
figcaption .label { display: block; font-weight: 600; color: var(--ink); margin-bottom: 2px; }
details.prompt summary { display: inline-block; cursor: pointer; list-style: none; color: var(--accent); font-size: .82rem; font-weight: 500; }
details.prompt summary::-webkit-details-marker { display: none; }
details.prompt summary::before { content: "▸"; display: inline-block; margin-right: 5px; transition: transform .15s; }
details.prompt[open] summary::before { transform: rotate(90deg); }
details.prompt p { margin: 5px 0 0; color: var(--ink-3); font-style: italic; font-size: .84rem; line-height: 1.5; }
figcaption .note { display: block; color: var(--ink-3); font-size: .82rem; margin-top: 3px; }
.showmore { margin-top: 16px; text-align: center; }

/* ---------- tabs ---------- */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.tab { padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line); background: #fff; cursor: pointer; font: inherit; font-size: .92rem; font-weight: 500; color: var(--ink-2); }
.tab:hover { background: var(--accent-soft); }
.tab.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.tab .count { opacity: .7; font-weight: 400; margin-left: 4px; }

/* ---------- input selector (thumbnail strip) ---------- */
.input-select { display: flex; gap: 10px; overflow-x: auto; padding: 4px 2px 10px; margin-bottom: 8px; }
.input-select button {
  flex: 0 0 auto; width: 120px; border: 2px solid var(--line); border-radius: 8px; padding: 0; background: #fff; cursor: pointer;
  overflow: hidden; text-align: left; font: inherit;
}
.input-select button img { width: 100%; aspect-ratio: var(--frame); object-fit: cover; }
.input-select button span { display: block; font-size: .75rem; padding: 4px 6px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.input-select button.active { border-color: var(--accent); }
.input-select button.active span { color: var(--accent); font-weight: 600; }
.input-meta { display: flex; gap: 14px; align-items: baseline; flex-wrap: wrap; margin-bottom: 12px; }
.input-meta .title { font-weight: 600; }
.input-meta .prompt { color: var(--ink-3); font-style: italic; font-size: .92rem; }

/* ---------- synchronised strip ---------- */
.strip { border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); padding: 14px; box-shadow: var(--shadow); }
.strip .grid { gap: 12px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
#comparisons .strip .grid { grid-template-columns: repeat(4, 1fr); }   /* 13 methods: 4 rows of larger clips */
.strip figure.vcard { box-shadow: none; }
.strip .vwrap { cursor: default; }
.strip-controls { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line); }
.strip-controls .ctl { display: inline-flex; gap: 4px; }
.strip-controls button {
  font: inherit; font-size: .9rem; border: 1px solid var(--line); background: #fff; border-radius: 6px; padding: 5px 10px; cursor: pointer; color: var(--ink);
}
.strip-controls button:hover { background: var(--accent-soft); }
.strip-controls button.primary { background: var(--accent); border-color: var(--accent); color: #fff; min-width: 84px; }
.scrub { flex: 1 1 260px; position: relative; padding-top: 6px; }
.scrub input[type=range] { width: 100%; margin: 0; accent-color: var(--accent); }
.scrub .ticks { position: relative; height: 16px; font-size: 11px; color: var(--ink-3); }
.scrub .ticks span { position: absolute; transform: translateX(-50%); white-space: nowrap; }
.scrub .ticks span::before { content: ""; position: absolute; left: 50%; top: -6px; width: 1px; height: 5px; background: var(--ink-3); }
.strip-controls .readout { font-family: var(--mono); font-size: .85rem; color: var(--ink-2); min-width: 130px; }
.strip-controls .hint { font-size: .8rem; color: var(--ink-3); flex-basis: 100%; }

/* ---------- rows (seeds: one row per method) ---------- */
.rows > .row { margin-bottom: 18px; }
.rows > .row h4 { margin: 0 0 8px; font-size: .95rem; color: var(--ink-2); }
.rows > .row h4.ours { color: var(--accent); }

/* ---------- figures ---------- */
.fig-grid { display: grid; gap: 24px; grid-template-columns: 1fr; }
figure.fig { margin: 0 0 8px; }
figure.fig img { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
figure.fig figcaption { padding: 10px 4px 0; }

/* ---------- bibtex ---------- */
pre.bibtex { background: #F5F5F5; border: 1px solid #DDDDDD; color: #333333; border-radius: var(--radius); padding: 16px; font-family: var(--mono); font-size: .85rem; overflow-x: auto; position: relative; margin: 0; }
.copy-btn { position: absolute; top: 10px; right: 10px; font: inherit; font-size: .8rem; padding: 4px 10px; border-radius: 6px; border: 1px solid #CCCCCC; color: #333333; background: #fff; cursor: pointer; }

/* ---------- floating global control ---------- */
.fab {
  position: fixed; right: 18px; bottom: 18px; z-index: 40; border: 1px solid var(--line); background: #fff; color: var(--ink);
  border-radius: 999px; padding: 9px 14px; font: inherit; font-size: .88rem; font-weight: 600; cursor: pointer; box-shadow: 0 4px 14px rgba(0,0,0,.14);
}
.fab:hover { background: var(--accent-soft); }

/* ---------- lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 50; background: rgba(10,12,16,.9); display: none; align-items: center; justify-content: center; padding: 24px; overflow-y: auto; }
.lightbox.open { display: flex; }
.lightbox .box { max-width: min(1100px, 96vw); width: 100%; margin: auto; }   /* auto margin: scrolls instead of clipping when an open prompt makes it taller than the screen */
.lightbox video { width: 100%; aspect-ratio: var(--frame); max-height: 78vh; object-fit: contain; background: #000; border-radius: 8px; }
.lightbox .cap { color: #e5e7eb; margin-top: 10px; font-size: .95rem; display: flex; flex-direction: column; gap: 4px; }
.lightbox .cap .txt { color: #9ca3af; font-style: italic; }
.lightbox details.prompt summary { font-style: normal; }
.lightbox details.prompt p { color: #cbd5e1; font-size: .9rem; }
.lightbox .close { position: absolute; top: 14px; right: 18px; color: #fff; font-size: 30px; background: none; border: 0; cursor: pointer; line-height: 1; }

footer { padding: 36px 0 48px; color: var(--ink-3); font-size: .85rem; border-top: 1px solid var(--line); }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .grid.cols-3, .grid.teaser { grid-template-columns: repeat(2, 1fr); }
  #comparisons .strip .grid { grid-template-columns: repeat(3, 1fr); }
  header.hero h1 { font-size: 2rem; }
}
@media (max-width: 560px) {
  .grid, .grid.cols-3, .grid.cols-4, .grid.teaser { grid-template-columns: 1fr 1fr; gap: 10px; }
  .strip .grid, #comparisons .strip .grid { grid-template-columns: 1fr 1fr; }
  figcaption { font-size: .8rem; padding: 7px 9px; }
  section { padding: 40px 0; }
  header.hero { padding: 40px 0 28px; }
  header.hero h1 { font-size: 1.7rem; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* ======================================================================
   Update: requirement badges, tables, placeholders, chart
   ====================================================================== */
.rq { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%;
      background: var(--accent); color: #fff; font-weight: 700; font-size: .9rem; flex: none; }
.rq.sm { width: 18px; height: 18px; font-size: .7rem; vertical-align: 2px; margin: 0 1px; }
.req-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 8px 0 14px; }
.req { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; box-shadow: var(--shadow); }
.req h4 { margin: 10px 0 6px; font-size: 1rem; }
.req p { margin: 0; font-size: .9rem; color: var(--ink-2); }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 18px 0 8px; }
.step { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.step-k { display: inline-block; font-size: .75rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--accent); }
.step h4 { margin: 4px 0 6px; font-size: 1rem; }
.step p { font-size: .9rem; color: var(--ink-2); margin: 0 0 8px; }
.step .rq-line { margin: 0; }
.formula { text-align: center; font-family: var(--mono); font-size: .95rem; background: var(--card); border: 1px solid var(--line);
           border-radius: var(--radius); padding: 10px 12px; }

.table-wrap { overflow-x: auto; margin: 10px 0 14px; -webkit-overflow-scrolling: touch; }
.narrow-tbl { max-width: 560px; }
table.tbl { width: 100%; border-collapse: collapse; font-size: .88rem; background: var(--card); }
table.tbl caption { caption-side: top; text-align: left; font-size: .82rem; color: var(--ink-3); padding: 0 0 6px; }
table.tbl th, table.tbl td { padding: 7px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
table.tbl thead th { font-weight: 600; color: var(--ink-2); border-bottom: 2px solid var(--line); white-space: nowrap; }
table.tbl.num td, table.tbl.num th { text-align: center; white-space: nowrap; }
table.tbl.num td:first-child, table.tbl.num th:first-child, table.tbl .l { text-align: left; }
table.tbl.num td.l { white-space: normal; min-width: 220px; color: var(--ink-2); }
table.tbl.us thead th { white-space: normal; min-width: 90px; }
table.tbl tr.ours td { background: var(--accent-soft); }
table.tbl tr.ours td:first-child { font-weight: 700; color: var(--accent-strong); }
table.tbl tr.grp td { background: var(--bg-soft); font-weight: 600; font-size: .82rem; color: var(--ink-2); }
details.more { margin: 6px 0 14px; }
details.more > summary { cursor: pointer; color: var(--accent); font-weight: 600; font-size: .92rem; }
details.more[open] > summary { margin-bottom: 6px; }

/* placeholders: dashed boxes for media still to be added */
.ph { position: relative; border: 2px dashed var(--accent); border-radius: var(--radius); background: repeating-linear-gradient(135deg, var(--bg-soft) 0 12px, var(--card) 12px 24px);
      padding: 30px 16px 14px; color: var(--ink-2); min-height: 120px; }
.ph b { display: block; color: var(--ink); margin-bottom: 4px; }
.ph p { margin: 0; font-size: .85rem; }
.ph-tag { position: absolute; top: 8px; left: 10px; font-size: .68rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
          background: var(--accent); color: #fff; border-radius: 4px; padding: 1px 6px; }
.ph.selected { border-style: solid; border-width: 3px; }
.wide-ph { margin: 14px 0; }
.ph-row { display: grid; grid-template-columns: minmax(0,1fr) auto minmax(0,3fr); gap: 14px; align-items: stretch; margin-bottom: 8px; }
.ph-row .ph { aspect-ratio: var(--frame); }
.ph-arrow { align-self: center; font-size: 1.8rem; color: var(--accent); }
.ph-alts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; min-width: 0; }
.ph-row > *, .ph-alts > * { min-width: 0; }
.ph-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 12px 0 18px; }
.ph-pair.three { grid-template-columns: repeat(3, 1fr); }

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.two-col h3 { margin-top: 0; }

/* Fig. 5 inline chart */
figure.chart { max-width: 760px; margin: 18px auto 8px; }
figure.chart svg { width: 100%; height: auto; display: block; font-family: var(--font); }
figure.chart .axis line { stroke: var(--ink-3); stroke-width: 1; }
figure.chart .axis line.grid { stroke: var(--line); }
figure.chart .axis text { fill: var(--ink-3); font-size: 12px; }
figure.chart .ref { stroke: var(--ink-3); stroke-dasharray: 4 4; stroke-width: 1; }
figure.chart .ref-t { fill: var(--ink-3); font-size: 11px; }
figure.chart polyline { fill: none; stroke-width: 2.5; }
figure.chart polyline.s-ours { stroke: var(--accent); }
figure.chart polyline.s-hy { stroke: var(--annot); stroke-dasharray: 6 4; }
figure.chart .dots.s-ours circle { fill: var(--accent); }
figure.chart .dots.s-hy circle { fill: var(--annot); }
figure.chart .vals text { font-size: 12px; fill: var(--ink-2); }
figure.chart .vals text.o { fill: var(--accent); font-weight: 700; }
figure.chart .key { display: inline-block; width: 18px; height: 3px; vertical-align: middle; margin-right: 4px; }
figure.chart .key.ours { background: var(--accent); }
figure.chart .key.hy { background: var(--annot); }

@media (max-width: 900px) {
  .req-grid { grid-template-columns: 1fr 1fr; }
  .steps, .two-col { grid-template-columns: 1fr; }
  .ph-row { grid-template-columns: 1fr; }
  .ph-arrow { transform: rotate(90deg); justify-self: center; }
}
@media (max-width: 560px) {
  .req-grid, .ph-alts, .ph-pair, .ph-pair.three { grid-template-columns: 1fr; }
}
#requirements table.tbl td:last-child { white-space: nowrap; }
.two-col > *, .steps > *, .req-grid > *, .ph-pair > * { min-width: 0; }

/* ---------- Teaser workflow figure (Fig. 1) ---------- */
.wf { --wf-blue: #1F5C99; --wf-teal: #2A7D74; display: grid; grid-template-columns: minmax(0, 15fr) 22px minmax(0, 85fr); gap: 10px; align-items: center; margin: 8px 0 28px; }
.wf > *, .wf-head > *, .wf-row > *, .wf-foot > *, .wf-alts > * { min-width: 0; }
.wf-title { margin: 0 0 10px; font-size: 1.05rem; font-weight: 700; color: var(--accent); text-align: center; line-height: 1.25; }
.wf-title.blue { color: var(--wf-blue); }
.wf-cap { margin: 10px 0 0; font-size: .82rem; line-height: 1.35; color: var(--ink); text-align: center; }
.wf-concept img { display: block; width: 100%; height: auto; }
.wf-arrow { position: relative; height: 2px; background: var(--accent); }
.wf-arrow::after { content: ""; position: absolute; right: -1px; top: -5px; border: 6px solid transparent; border-left: 9px solid var(--accent); border-right: 0; }
.wf-arrow.blue { background: var(--wf-blue); }
.wf-arrow.blue::after { border-left-color: var(--wf-blue); }
.wf-panel { display: flex; flex-direction: column; gap: 12px; }
.wf-head, .wf-row, .wf-foot { display: grid; grid-template-columns: minmax(0, 19fr) 22px minmax(0, 81fr); gap: 10px; align-items: center; }
.wf-row { border: 2px solid var(--accent); border-radius: 16px; padding: 14px 16px 22px; background: #fff; }
.wf-head, .wf-foot { padding: 0 18px; }
.wf-input img { display: block; width: 100%; aspect-ratio: 571 / 455; object-fit: cover; border-radius: 10px; border: 5px solid #EEF0F3; }
.wf-head .wf-title { margin: 0; align-self: start; }
.wf-head-out { align-self: start; text-align: center; }
.wf-note { margin: 3px 0 0; font-size: .8rem; line-height: 1.35; color: var(--muted, #6b7280); font-style: italic; }
.wf-head-out:first-child .wf-note { white-space: nowrap; margin-left: -40px; margin-right: -40px; }
.wf-badge b { font-weight: 700; color: var(--accent); }
.wf-foot .wf-cap { margin: 0; }
.wf-foot .wf-legend { margin-top: 0; }
.wf-input { position: relative; }
.wf-tag { position: absolute; left: 50%; top: calc(100% + 4px); transform: translateX(-50%); white-space: nowrap; font-size: .78rem; font-weight: 600; color: var(--ink); line-height: 1.2; }
.wf-input img.sketch { object-fit: cover; background: #fff; }
.wf-fork { position: relative; align-self: stretch; }
.wf-fork svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.wf-fork .ln { fill: none; stroke: var(--wf-blue); stroke-width: 2; }
.wf-fork path:not(.ln) { fill: var(--wf-blue); }
.wf-alts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.wf-alt { position: relative; margin: 0; padding: 6px 6px 8px; background: #F4F5F7; border: 2px solid #E3E5E9; border-radius: 12px; }
.wf-alt.selected { border-color: var(--wf-teal); background: #fff; }
.wf-alt video { display: block; width: 100%; aspect-ratio: 832 / 480; object-fit: cover; border-radius: 6px; background: #ddd; }
.wf-badge { position: absolute; top: 12px; left: 12px; z-index: 1; display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px 2px 5px; border-radius: 999px; background: rgba(255,255,255,.92); font-size: .78rem; font-weight: 600; color: var(--ink); }
.wf-badge .loop { width: 14px; height: 14px; fill: none; stroke: var(--accent); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.wf .ck { width: 16px; height: 16px; flex: none; }
.wf .ck circle { fill: var(--wf-teal); }
.wf .ck path { fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.wf-checks { display: flex; justify-content: center; gap: 3px; margin-top: 7px; }
.wf-legend { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 14px; align-items: center; margin-top: 12px; padding: 10px 14px; border: 2px solid var(--wf-teal); border-radius: 12px; }
.wf-legend p { margin: 0; font-size: .82rem; line-height: 1.35; color: var(--wf-teal); font-weight: 600; border-right: 1px solid #CFE3E0; padding-right: 12px; }
.wf-legend ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 6px 14px; }
.wf-legend li { display: flex; align-items: center; gap: 6px; font-size: .85rem; }
@media (max-width: 900px) {
  .wf, .wf-head, .wf-row, .wf-foot { grid-template-columns: 1fr; }
  .wf-head, .wf-foot { padding: 0; }
  .wf-head-out:first-child .wf-note { white-space: normal; margin-left: 0; margin-right: 0; }
  .wf-arrow { width: 2px; height: 22px; justify-self: center; }
  .wf-arrow::after { right: auto; top: auto; left: -5px; bottom: -1px; border: 6px solid transparent; border-top: 9px solid var(--accent); border-bottom: 0; }
  .wf-arrow.blue::after { border-left-color: transparent; border-top-color: var(--wf-blue); }
  .wf-concept, .wf-input { max-width: 360px; justify-self: center; }
  .wf-sp { display: none; }
  .wf-tag { position: static; display: block; transform: none; text-align: center; margin-top: 4px; }
  .wf-fork { align-self: auto; width: 2px; height: 22px; justify-self: center; background: var(--wf-blue); }
  .wf-fork svg { display: none; }
  .wf-fork::after { content: ""; position: absolute; left: -5px; bottom: -1px; border: 6px solid transparent; border-top: 9px solid var(--wf-blue); border-bottom: 0; }
}
@media (max-width: 600px) {
  .wf-alts { grid-template-columns: 1fr; }
  .wf-legend { grid-template-columns: 1fr; }
  .wf-legend p { border-right: 0; padding-right: 0; }
}
.ph-quad { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 8px 0 18px; }
.ph-quad .ph { min-height: 150px; padding-top: 30px; }
@media (max-width: 900px) { .ph-quad { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .ph-quad { grid-template-columns: 1fr; } }
.fm-clip { margin: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); overflow: hidden; box-shadow: var(--shadow); }
.fm-clip video { display: block; width: 100%; aspect-ratio: 832 / 480; object-fit: cover; background: #ddd; }
.fm-clip figcaption { padding: 10px 12px 12px; }
.fm-clip figcaption b { display: block; color: var(--ink); margin-bottom: 4px; }
.fm-clip figcaption p { margin: 0; font-size: .85rem; color: var(--muted, #6b5a64); }
figure.fig.fig-tall { max-width: 760px; margin-left: auto; margin-right: auto; }
figure.fig.fig-tall figcaption { text-align: center; }
.fig-tall img { display: block; width: 100%; height: auto; }
/* Design alternatives: shared input -> arrow -> seeds */
.seed-flow { display: grid; grid-template-columns: minmax(0, 1fr) 28px minmax(0, 3fr); gap: 12px; align-items: center; }
.seed-flow > * { min-width: 0; }
.seed-input .vwrap img { display: block; width: 100%; height: 100%; object-fit: cover; }
.seed-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 900px) {
  .seed-flow { grid-template-columns: 1fr; }
  .seed-input { max-width: 320px; justify-self: center; width: 100%; }
}
@media (max-width: 600px) { .seed-grid { grid-template-columns: 1fr; } }
.strip .grid > .strip-group { grid-column: 1 / -1; margin: 14px 0 2px; font-size: .95rem; font-weight: 700; color: var(--ink); }
.strip .grid > .strip-group:first-child { margin-top: 0; }
/* Comparison strip: shared input -> arrow in the first grid cell, method videos flow after it (4 per row) */
.strip .grid.has-lead > .strip-lead { display: grid; grid-template-columns: minmax(0, 1fr) 22px; gap: 8px; align-items: center; align-self: start; }
.strip .grid.has-lead > .strip-lead .seed-input { min-width: 0; }
#comparisons .strip .grid.has-lead { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 900px) {
  #comparisons .strip .grid.has-lead { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .strip .grid.has-lead > .strip-lead { grid-column: 1 / -1; grid-template-columns: 1fr; justify-items: center; }
  .strip .grid.has-lead > .strip-lead .seed-input { max-width: 320px; width: 100%; }
}
@media (max-width: 520px) { #comparisons .strip .grid.has-lead { grid-template-columns: 1fr; } }
h4.sub-h { margin: 40px 0 4px; font-size: 1rem; font-weight: 700; color: var(--ink); }
h4.sub-h + p { margin-top: 0; }
figure.fig.us-chart { margin: 8px 0 6px; }
figure.fig.us-chart img { display: block; width: 100%; height: auto; }
details.more details.more { margin-top: 6px; }

/* comparison strip: placeholder card for a clip still to be added */
.strip-ph .vwrap.ph { padding: 0; min-height: 0; border-width: 2px; }

/* comparison strip: requirement marks ①–④ per clip (pink filled = met, coral outline = not met) + legend + failure filter */
:root { --fail: #F26B5B; }
.req-marks { display: flex; gap: 3px; margin-top: 6px; }
.rqm { display: inline-flex; align-items: center; justify-content: center; width: 18px; height: 18px; border-radius: 50%;
       background: var(--accent); color: #fff; font-size: .68rem; font-weight: 700; line-height: 1; flex: none; position: relative; }
.rqm.fail { background: #fff; color: var(--fail); box-shadow: inset 0 0 0 1.5px var(--fail); }
.req-legend { display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: center; margin: 0 0 14px; padding: 10px 14px;
              background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); font-size: .85rem; color: var(--ink-2); }
.req-key, .req-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.req-key-title { font-weight: 600; color: var(--ink); }
.req-key-item { display: inline-flex; align-items: center; gap: 5px; }
.req-filter { margin-left: auto; gap: 6px; }
.req-btn { border: 1px solid var(--line); background: var(--card); border-radius: 999px; padding: 3px 7px; cursor: pointer; display: inline-flex; }
.req-btn:hover { border-color: var(--fail); }
.req-btn.active { background: #FDE7E4; border-color: var(--fail); }
#comparisons-mount figure.vcard[data-fails] { transition: opacity .2s; }
#comparisons-mount[data-req-filter="1"] figure.vcard[data-fails]:not([data-fails~="1"]),
#comparisons-mount[data-req-filter="2"] figure.vcard[data-fails]:not([data-fails~="2"]),
#comparisons-mount[data-req-filter="3"] figure.vcard[data-fails]:not([data-fails~="3"]),
#comparisons-mount[data-req-filter="4"] figure.vcard[data-fails]:not([data-fails~="4"]) { opacity: .25; }
@media (max-width: 700px) { .req-filter { margin-left: 0; } }
/* requirements table: header row of empty circles ①–④; cells filled = met, coral outline = not met */
.rqm.empty { background: #fff; color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent); }
.rqm.part { background: color-mix(in srgb, var(--accent) 22%, #fff); color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent); }
.tbl .req-marks { margin-top: 0; flex-wrap: nowrap; }
.req-table-key { display: flex; justify-content: flex-end; gap: 14px; margin: 6px 0 14px; }
/* section intro paragraphs that span the full section width */
#teaser .section-head p,
#requirements .section-head p,
#method .section-head p,
#results .section-head p,
#comparisons .section-head p,
#seeds .section-head p,
#user-study .section-head p,
#stages .section-head p,
#ablations .section-head p,
#limitations .section-head p { max-width: none; }
/* abstract stat tiles: DesignOrbit vs. the strongest baseline, side by side */
.stat.cmp { padding: 12px 14px 12px; }
.stat-title { font-size: .8rem; font-weight: 600; color: var(--ink-2); margin-bottom: 6px; }
.stat-pair { display: flex; align-items: flex-end; justify-content: center; gap: 10px; }
.stat-pair .side { display: flex; flex-direction: column; align-items: center; min-width: 0; }
.stat-pair .side b { display: block; line-height: 1.15; }
.stat-pair .side.ours b { font-size: 1.45rem; color: var(--accent); }
.stat-pair .side.base b { font-size: 1.05rem; color: var(--ink-3); font-weight: 600; }
.stat-pair small { font-size: .72rem; color: var(--ink-3); line-height: 1.2; }
.stat-pair .stat-vs { font-size: .75rem; color: var(--ink-3); padding-bottom: 18px; }
.stats:has(.stat.cmp) { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 520px) { .stats:has(.stat.cmp) { grid-template-columns: 1fr; } }
