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

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
}

body {
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-ui);
  -webkit-font-smoothing: antialiased;
}

html {
  scroll-behavior: smooth;
}

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

html {
  --font-ui: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --font-display: "Newsreader", Georgia, serif;
  --font-text: var(--font-display);

  --bar-height: 56px;
  --chrome-gutter: var(--space-block);
}

a {
  color: inherit;
  text-decoration: none;
}

::selection {
  background: var(--selection);
  color: var(--selection-fg);
}

::-moz-selection {
  background: var(--selection);
  color: var(--selection-fg);
}

p {
  margin: 0;
}

.footer-label,
.season-current,
.season-menu button,
.bar-links a,
.bar-name {
  font-family: var(--font-ui);
  font-size: var(--type-chrome);
  font-weight: 500;
  letter-spacing: var(--track-chrome);
  text-transform: uppercase;
  line-height: 1.4;
}

/* Page sits above the footer */
.page {
  position: relative;
  z-index: 1;
  flex: 1;
  background: var(--bg);
}

.bar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--bar-height);
  padding: 0 var(--chrome-gutter);
  background: var(--bg);
}

.bar-start {
  display: flex;
  align-items: center;
  gap: var(--space-stack);
  min-width: 0;
}

.bar-name {
  margin: 0;
  color: var(--fg);
  white-space: nowrap;
}

.bar-start .season-current {
  color: var(--accent);
}

.bar-links a:hover {
  color: var(--fg);
}

.bar-end {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-block);
}

.bar-links {
  display: flex;
  gap: var(--space-block);
}

.bar-links .nav-pair {
  word-spacing: -0.28em;
}

.bar-menu {
  display: none;
  padding: 0;
  border: 0;
  background: none;
  color: var(--fg-muted);
  line-height: 0;
}

.bar-menu:hover,
.bar-menu[aria-expanded="true"] {
  color: var(--fg);
}

.bar-menu:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

.bar-menu svg {
  display: block;
  width: 14px;
  height: 14px;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

.bar-links a {
  position: relative;
  width: max-content;
  padding-bottom: 3px;
  color: var(--fg-muted);
  transition: color 0.2s ease;
}

.bar-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s ease;
}

.bar-links a:hover::after,
.bar-links a:focus-visible::after,
.bar-links a[aria-current="page"]::after {
  transform: scaleX(1);
}

.bar-links a[aria-current="page"],
.bar-links a[aria-current="page"]:hover {
  color: var(--accent);
}

/* Season picker: the current season, opening a small menu of all four */
.season-picker {
  position: relative;
}

.season-current,
.season-menu button {
  display: flex;
  align-items: center;
  gap: var(--space-tight);
  padding: 0;
  border: 0;
  background: none;
  color: var(--fg-muted);
  transition: color 0.2s ease;
}

.season-current,
.season-current:hover,
.season-current[aria-expanded="true"] {
  color: var(--accent);
}

.season-menu button:hover {
  color: var(--fg);
}

.season-menu button[aria-checked="true"] {
  color: var(--accent);
}

.season-icon {
  flex: none;
}

.season-menu {
  position: absolute;
  top: calc(100% + var(--space-stack));
  left: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-stack);
  min-width: 140px;
  padding: var(--space-stack);
  background: var(--bg);
  border: 1px solid var(--border);
}

.season-menu[hidden] {
  display: none;
}

.season-current:focus-visible,
.season-menu button:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

@media (max-width: 560px) {
  .bar-end {
    gap: var(--space-stack);
  }

  .bar-menu {
    display: block;
  }

  .bar-links {
    display: none;
    position: absolute;
    top: calc(100% + var(--space-stack));
    right: 0;
    z-index: 1;
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-stack);
    min-width: 140px;
    padding: var(--space-stack);
    background: var(--bg);
    border: 1px solid var(--border);
  }

  .bar.is-open .bar-links {
    display: flex;
  }

  .season-current span {
    display: none;
  }
}

/* Content bands: work list and about */
.band {
  width: min(var(--content), calc(100% - 2 * var(--chrome-gutter)));
  margin-inline: auto;
  padding: var(--space-grid) 0 var(--space-section);
}

.home .band,
.band-page {
  width: auto;
  max-width: none;
  padding: var(--space-tight) var(--chrome-gutter) var(--space-section);
}

.home-hero {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: calc(72vh - var(--bar-height));
  padding: var(--space-grid) var(--chrome-gutter);
  box-sizing: border-box;
}

.home-sprite {
  display: block;
  width: clamp(104px, 12vw, 168px);
  height: auto;
  aspect-ratio: var(--sprite-w, 1) / var(--sprite-h, 1);
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  animation: home-bob 8s ease-in-out infinite;
}

.home-moo {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 20;
  padding: 5px 8px;
  background: var(--fg);
  color: var(--bg);
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  line-height: 1;
  pointer-events: none;
  white-space: nowrap;
}

.home-moo[hidden] {
  display: none;
}

@keyframes home-bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.home-intro {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.15em;
  width: 100%;
  max-width: var(--content);
  margin-inline: auto;
}

.home-title {
  max-width: 22em;
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(28px, 2vw + 18px, 44px);
  font-weight: 400;
  letter-spacing: var(--track-display);
  line-height: 1.2;
  text-wrap: balance;
}

.home-roles {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  column-gap: var(--space-stack);
  row-gap: 12px;
  align-items: baseline;
  margin: 0.6em 0 0;
}

.home-role {
  display: contents;
}

.home-role dt {
  color: var(--accent);
  font-family: var(--font-ui);
  font-size: clamp(12px, 0.25vw + 11.5px, 15px);
  font-weight: 500;
  letter-spacing: var(--track-chrome);
  line-height: 1.4;
  text-transform: uppercase;
}

.home-role dd {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(16px, 0.7vw + 13.5px, 21px);
  line-height: 1.45;
  text-wrap: pretty;
}

.home .band.home-work {
  padding-top: var(--space-grid);
  scroll-margin-top: var(--bar-height);
}

.quests-page {
  padding-top: var(--space-grid);
}

.quests {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-width: var(--content);
  margin-inline: auto;
}

.quests .work-list {
  width: 100%;
  max-width: none;
  margin-inline: 0;
  margin-top: var(--space-section);
}

.page-title {
  margin: 0 0 var(--space-block);
  font-family: var(--font-display);
  font-size: var(--type-page);
  font-weight: 400;
  letter-spacing: var(--track-page);
  line-height: 1.15;
}

.work-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 16px;
  row-gap: 32px;
  max-width: var(--content);
  margin-inline: auto;
}

a,
button,
[role="menuitemradio"],
a *,
button *,
.season-current,
.season-menu button,
.bar-menu,
.home-sprite-cow {
  cursor: url("hoof.svg") 12 2, pointer;
}

.work-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  color: inherit;
}

.work-card:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 4px;
}

.slot.work-frame {
  aspect-ratio: 16 / 10;
  min-height: 0;
  border: 1px solid var(--accent);
  border-radius: 0;
}

.work-card .work-frame {
  position: relative;
  width: 100%;
  min-height: 0;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border: 0;
  border-radius: 0;
  background: var(--wash);
}

.work-frame img,
.work-frame video {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.work-frame video {
  object-position: top;
}

.work-card .work-frame::before,
.work-card .work-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.work-card .work-frame::before {
  z-index: 1;
  background: transparent;
  transition: background-color 0.3s ease-in-out;
}

.work-card .work-frame::after {
  z-index: 2;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--fg) 5%, transparent);
}

@media (hover: hover) {
  .work-card:hover .work-frame::before,
  .work-card:focus-visible .work-frame::before {
    background: color-mix(in srgb, #fff 30%, transparent);
  }
}

.work-copy {
  min-width: 0;
  font-size: var(--type-body);
  line-height: 1.4;
}

.work-title,
.work-note {
  display: inline;
  margin: 0;
  font-family: var(--font-text);
  font-size: inherit;
  font-weight: 400;
  letter-spacing: var(--track-meta);
  line-height: inherit;
}

.work-title {
  color: var(--fg);
}

.work-note {
  color: color-mix(in srgb, var(--fg) 45%, transparent);
}

.about-page {
  padding-top: var(--space-grid);
}

.about {
  max-width: var(--content);
  margin-inline: auto;
}

.about > * + * {
  margin-top: var(--space-section);
}

.about-split {
  display: grid;
  grid-template-columns: 8.5rem minmax(0, 42rem);
  column-gap: 2.5rem;
  align-items: start;
}

.about-list {
  grid-column: 2;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.about-list li {
  display: grid;
  grid-template-columns: 10.5rem minmax(0, 1fr);
  column-gap: 2rem;
  align-items: start;
}

.about-label {
  grid-column: 1;
  margin: 0;
  color: var(--accent);
  font-family: var(--font-ui);
  font-size: var(--type-label);
  font-weight: 500;
  letter-spacing: var(--track-chrome);
  line-height: 1.4;
  text-transform: uppercase;
}

.about-index {
  font-variant-numeric: tabular-nums;
}

.about-list .about-year {
  grid-column: 1;
  font-size: var(--type-label);
  font-weight: 400;
  letter-spacing: var(--track-body);
  line-height: 1.4;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.about-list .about-entry {
  grid-column: 2;
}

.about-copy,
.about-entry,
.about-portrait {
  grid-column: 2;
}

.about-year,
.about-detail,
.about-copy p {
  margin: 0;
  color: var(--fg-muted);
  font-family: var(--font-ui);
  font-weight: 400;
  letter-spacing: var(--track-meta);
  line-height: 1.45;
}

.about-year,
.about-detail {
  font-size: var(--type-meta);
}

.about-copy p {
  font-family: var(--font-text);
  font-size: var(--type-body);
  letter-spacing: var(--track-body);
  line-height: 1.65;
}

.about-copy p + p {
  margin-top: var(--space-stack);
}

.about-name {
  margin: 0;
  color: var(--fg);
  font-family: var(--font-display);
  font-size: var(--type-body);
  font-weight: 500;
  letter-spacing: var(--track-body);
  line-height: 1.4;
}

.about-detail {
  margin-top: 2px;
}

.about-name a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

.about-name a:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

.about-portrait {
  display: block;
  width: min(100%, 440px);
  height: auto;
  border-radius: var(--radius);
}

.slot {
  min-height: 180px;
  border-radius: var(--radius);
  background: var(--fill);
}

@media (max-width: 720px) {
  .home-roles {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 4px;
  }

  .home-role:not(:first-child) dt {
    margin-top: 8px;
  }

  .work-list {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-block);
  }

  .about-split {
    grid-template-columns: 1fr;
    row-gap: 6px;
  }

  .about-copy,
  .about-portrait,
  .about-list,
  .about-label {
    grid-column: 1;
  }

  .about-list li {
    grid-template-columns: 8.5rem minmax(0, 1fr);
    column-gap: 1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .home-sprite {
    animation: none;
  }

  .bar-links a::after,
  .project-year-thumb {
    transition: none;
  }

  .work-card,
  .work-card .work-frame::before {
    transition: none;
  }
}

/* Case studies
   Head (title, lead, facts) → hero → sticky section nav beside the story → pager.
   Every section opens with a label and a one-line takeaway, so skimming
   the headings alone tells the story. */
.project {
  scroll-margin-top: var(--bar-height);
}

.project-head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.project-head .project-prose {
  margin-top: var(--space-stack);
}

.project-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: var(--type-project);
  font-weight: 400;
  letter-spacing: var(--track-display);
  line-height: 1.08;
  text-wrap: balance;
}

.project-lead {
  margin: var(--space-stack) 0 0;
  max-width: 24em;
  color: color-mix(in srgb, var(--fg) 62%, transparent);
  font-family: var(--font-display);
  font-size: var(--type-section);
  font-weight: 400;
  letter-spacing: var(--track-section);
  line-height: 1.3;
  text-wrap: pretty;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 0;
  margin: var(--space-block) 0 0;
  padding: 0;
  list-style: none;
  color: var(--fg-muted);
  font-family: var(--font-ui);
  font-size: var(--type-meta);
  line-height: 1.5;
}

.project-tags li {
  white-space: nowrap;
}

.project-tags li:not(:last-child)::after {
  content: "·";
  margin-inline: 0.6em;
}

.project-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
  gap: var(--space-block) var(--space-grid);
  width: 100%;
  margin: var(--space-grid) 0 0;
  padding-top: var(--space-block);
  border-top: 1px solid var(--border);
}

.project-facts dt,
.project-label,
.project-summary dt,
.project-toc a {
  font-family: var(--font-ui);
  font-size: var(--type-meta);
  font-weight: 500;
  letter-spacing: var(--track-chrome);
  line-height: 1.4;
  text-transform: uppercase;
}

.project-facts dt {
  margin: 0 0 var(--space-tight);
  color: var(--accent);
}

.project-facts dd {
  margin: 0;
  font-family: var(--font-text);
  font-size: var(--type-body);
  line-height: 1.5;
}

.project-media.project-hero {
  margin: var(--space-grid) 0 0;
}

.project-hero .project-media-frame {
  --ratio: 16 / 9;
}

.project-layout {
  margin-top: var(--space-section);
}

/* Section nav: built by project.js from the h2 labels. On wide screens it sits
   in the left margin, lined up with the bar, and the story shifts right to make room. */
.project-toc {
  display: none;
}

@media (min-width: 1101px) {
  .project {
    --project-inset: max(
      calc(var(--chrome-gutter) + var(--toc-width) + var(--space-grid)),
      calc((100vw - var(--content)) / 2)
    );
    width: auto;
    max-width: var(--content);
    margin-left: var(--project-inset);
    margin-right: var(--chrome-gutter);
  }

  .project-layout {
    position: relative;
  }

  .project-toc {
    display: block;
    position: absolute;
    top: 0;
    bottom: 0;
    left: calc(var(--chrome-gutter) - var(--project-inset));
    width: var(--toc-width);
  }
}

.project-toc ol {
  position: sticky;
  top: calc(var(--bar-height) + var(--space-grid));
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.project-toc a {
  display: block;
  color: var(--fg-muted);
  font-size: var(--type-nav);
  font-weight: 400;
  letter-spacing: 0.06em;
  transition: color 0.2s ease;
}

.project-toc a:hover {
  color: var(--fg);
}

.project-toc a[aria-current="true"] {
  color: var(--accent);
  font-weight: 500;
}

.project-toc a[data-locked] {
  opacity: 0.5;
}

.project-toc a:focus-visible,
.project-top:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

.project-body {
  display: flex;
  flex-direction: column;
  gap: calc(var(--space-section) * 1.5);
  min-width: 0;
}

.project-section {
  display: flex;
  flex-direction: column;
  gap: var(--space-block);
  scroll-margin-top: calc(var(--bar-height) + var(--space-grid));
}

.project-label {
  display: flex;
  gap: var(--space-tight);
  margin: 0;
  color: var(--accent);
}

.project-index {
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}

.project-heading {
  margin: calc(var(--space-tight) - var(--space-block)) 0 0;
  max-width: 22em;
  font-family: var(--font-display);
  font-size: var(--type-headline);
  font-weight: 400;
  letter-spacing: var(--track-section);
  line-height: 1.25;
  text-wrap: balance;
}

.project-prose {
  display: flex;
  flex-direction: column;
  gap: var(--space-stack);
  max-width: 38em;
}

.project-prose p,
.project-points p,
.project-summary dd,
.project-stats dd {
  margin: 0;
  font-family: var(--font-text);
  font-size: var(--type-body);
  font-weight: 400;
  letter-spacing: var(--track-body);
  line-height: 1.65;
}

/* At a glance: three short reads at the top of the overview */
.project-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-grid);
  margin: 0;
}

.project-summary > div,
.project-points > li,
.project-stats > div {
  padding-top: var(--space-stack);
  border-top: 1px solid var(--border);
}

.project-summary dt {
  margin: 0 0 var(--space-tight);
  color: var(--fg-muted);
}

.project-summary dd {
  line-height: 1.55;
}

/* Visuals. Swap a .project-media-frame div for an <img> with the same class. */
.project-media {
  display: flex;
  flex-direction: column;
  gap: var(--space-tight);
  margin: var(--space-tight) 0;
}

.project-media-frame {
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: var(--ratio, 16 / 10);
  padding: var(--space-block);
  background: var(--wash);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--fg) 5%, transparent);
  color: color-mix(in srgb, var(--fg) 45%, transparent);
  font-family: var(--font-ui);
  font-size: var(--type-meta);
  line-height: 1.5;
  text-align: center;
}

img.project-media-frame,
video.project-media-frame {
  display: block;
  height: auto;
  padding: 0;
  object-fit: cover;
}

video.project-media-frame {
  object-position: top;
}

.project-media--dark .project-media-frame {
  background: var(--fg);
  color: color-mix(in srgb, var(--bg) 60%, transparent);
}

.project-media.is-plain .project-media-frame {
  background: var(--bg);
}

.project-media.is-card .project-media-frame {
  background: var(--card);
  box-shadow: inset 0 0 0 1px var(--border);
}

.project.is-bare .project-media-frame {
  box-shadow: none;
}

.project-media figcaption {
  color: var(--fg-muted);
  font-family: var(--font-ui);
  font-size: var(--type-meta);
  line-height: 1.5;
}

/* Mismatched rows in the Button audit. The tint follows the season. */
.audit-frame {
  position: relative;
}

.audit-mark {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: var(--w);
  height: var(--h);
  border: 2px solid var(--accent);
  border-radius: 6px;
  background: color-mix(in srgb, var(--accent) 16%, transparent);
  opacity: 0;
  pointer-events: none;
  animation: audit-mark 7.5s ease-in-out infinite;
}

.audit-mark.is-b {
  animation-delay: 2.5s;
}

.audit-mark.is-c {
  animation-delay: 5s;
}

.audit-mark.is-still {
  opacity: 1;
  animation: none;
}

@keyframes audit-mark {
  0% { opacity: 0; }
  6%, 28% { opacity: 1; }
  34%, 100% { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .audit-mark {
    animation: none;
    opacity: 1;
  }
}

.catch-frame {
  position: relative;
  container-type: inline-size;
}

.catch-bridge {
  position: absolute;
  left: 39.3%;
  width: 21.4%;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55em;
  margin: 0;
  padding: 0 0.35em;
  color: var(--accent);
  text-align: center;
  pointer-events: none;
}

.catch-bridge-label {
  font-family: var(--font-ui);
  font-size: clamp(10px, 1.45cqi, 13px);
  font-weight: 500;
  line-height: 1.25;
}

.catch-bridge-arrow {
  display: block;
  width: 100%;
  height: 0.75em;
  overflow: visible;
}

.catch-bridge-arrow line,
.catch-bridge-arrow polyline {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5px;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

.project-media.is-inset .project-media-frame,
.project-media.is-inset figcaption {
  width: min(100%, 640px);
  align-self: flex-start;
}

.project-summary.is-challenges {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.project-summary.is-pair {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.project-aside {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: var(--space-grid);
  align-items: center;
}

.project-aside.is-flip > .project-aside-copy {
  order: 2;
}

.project-aside-copy h3 {
  margin: 0 0 var(--space-tight);
  font-family: var(--font-display);
  font-size: var(--type-section);
  font-weight: 400;
  letter-spacing: var(--track-section);
  line-height: 1.25;
}

.project-aside-copy p {
  margin: 0;
  max-width: 28em;
  font-family: var(--font-text);
  font-size: var(--type-body);
  letter-spacing: var(--track-body);
  line-height: 1.65;
}

.project-aside .project-media {
  margin: 0;
}

.project-challenge-icon {
  display: block;
  width: auto;
  height: 52px;
  margin: 0 0 var(--space-stack);
  object-fit: contain;
  object-position: left bottom;
}

.foundations-board {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.foundations-board li {
  grid-column: span 2;
  min-width: 0;
}

.foundations-board li:nth-child(4) {
  grid-column: 2 / 4;
}

.foundations-board li:nth-child(5) {
  grid-column: 4 / 6;
}

.foundations-board img {
  display: block;
  width: 100%;
  height: auto;
}

.foundations-board p {
  margin: var(--space-tight) 0 0;
  font-family: var(--font-display);
  font-size: var(--type-label);
  font-weight: 500;
  letter-spacing: var(--track-entry);
  line-height: 1.3;
}

.token-map {
  display: grid;
  gap: var(--space-block);
}

.token-map ol {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.token-map li {
  display: grid;
  grid-template-columns: 5.75rem max-content;
  align-items: center;
  gap: var(--space-tight);
  min-width: 0;
}

.token-map li > span {
  color: var(--fg);
  font-family: var(--font-display);
  font-size: var(--type-label);
  font-weight: 500;
  letter-spacing: var(--track-entry);
  line-height: 1.2;
  text-align: right;
}

.token-map code {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: max-content;
  max-width: 100%;
  padding: 6px 12px 6px 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--fill);
  color: var(--fg);
  font-family: var(--font-ui);
  font-size: 11px;
  line-height: 1.3;
  white-space: nowrap;
}

.token-map code i {
  display: block;
  width: 12px;
  height: 12px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #ffc700;
}

.token-map .is-value {
  width: auto;
  padding: 0;
  border: 0;
  background: none;
  color: var(--fg);
  font-size: 12px;
}

.token-map-example {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-stack);
  padding-left: calc(5.75rem + var(--space-tight));
}

.token-map-alert {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 10px 14px;
  border-radius: 12px;
  background: #ffc700;
  color: #232323;
  font-family: var(--font-display);
  font-size: var(--type-label);
  font-weight: 500;
  line-height: 1.3;
}

.token-map-alert svg {
  flex: 0 0 auto;
}

.token-map-example > code {
  width: auto;
  padding: 0;
  border: 0;
  background: none;
  color: var(--fg);
  font-size: 11px;
  white-space: normal;
}

.project-media-card {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--card);
  box-shadow: inset 0 0 0 1px var(--border);
}

.project-media-card > img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-media-card.is-inset {
  display: grid;
  place-items: center;
  padding: var(--space-stack);
}

.project-media-card.is-inset > * {
  width: 100%;
}

.project-media-card.is-inset > .token-map {
  width: min(100%, 28rem);
}

.project-media-card .token-map {
  gap: 14px;
  justify-items: center;
}

.project-media-card .token-map ol {
  gap: 10px;
  width: 100%;
}

.project-media-card .token-map li {
  grid-template-columns: 6.25rem minmax(0, 1fr);
}

.project-media-card .token-map li > span {
  font-size: 16px;
}

.project-media-card .token-map code {
  gap: 10px;
  width: auto;
  max-width: 100%;
  padding: 8px 14px 8px 10px;
  font-size: 13px;
  white-space: nowrap;
}

.project-media-card .token-map code i {
  width: 14px;
  height: 14px;
}

.project-media-card .token-map .is-value {
  font-size: 14px;
}

.project-media-card .token-map-example {
  padding-left: 0;
  align-items: center;
}

.project-media-card .token-map-alert {
  padding: 12px 16px;
  font-size: 15px;
}

.project-media-card .token-map-example > code {
  font-size: 13px;
}

.project-media-card .foundations-board p {
  font-size: 13px;
}

.project-media-card.is-collage {
  display: grid;
  gap: 8px;
  padding: 12px;
}

.project-media-card.is-duo {
  grid-template-columns: 1fr 1fr;
}

.project-media-card.is-trio {
  grid-template-columns: 1.35fr 1fr;
  grid-template-rows: 1fr 1fr;
}

.project-media-card.is-trio > img:first-child {
  grid-row: 1 / -1;
}

.project-media-card.is-collage > img {
  min-width: 0;
  min-height: 0;
  border-radius: var(--radius);
  box-shadow: 0 6px 18px color-mix(in srgb, var(--fg) 12%, transparent);
}

.project-media-card.is-duo > figure {
  display: flex;
  flex-direction: column;
  gap: var(--space-tight);
  min-width: 0;
  min-height: 0;
  margin: 0;
}

.project-media-card.is-duo > figure img {
  flex: 1;
  min-height: 0;
  width: 100%;
  object-fit: cover;
  object-position: left top;
  border-radius: var(--radius);
}

.project-media-card.is-duo figcaption {
  margin: 0;
  font-family: var(--font-display);
  font-size: var(--type-label);
  font-weight: 500;
  letter-spacing: var(--track-entry);
  line-height: 1.3;
}

.project-media-card.is-trio > img:nth-child(2) {
  margin-top: 6px;
}

.project-media-card.is-trio > img:nth-child(3) {
  margin-bottom: 6px;
}

.project-media-card.is-contain {
  padding: var(--space-block);
}

.project-media-card.is-contain > img {
  object-fit: contain;
}

.project-media-card.is-logo {
  display: grid;
  place-items: center;
}

.project-media-card.is-logo > img {
  width: 82%;
  height: 82%;
}

.project-media-card.is-natural {
  aspect-ratio: auto;
  height: auto;
}

video.project-media-card {
  display: block;
  object-fit: contain;
}

.project-media-card .is-end {
  object-position: right center;
}

.project-media-pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-stack);
}

.project-media-pair .project-media {
  margin: 0;
}

/* Numbered points: principles, lessons */
.project-points {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-grid);
  margin: var(--space-tight) 0;
  padding: 0;
  list-style: none;
}

.project-points .project-index {
  display: block;
  margin-bottom: var(--space-tight);
  color: var(--accent);
  font-family: var(--font-ui);
  font-size: var(--type-meta);
  font-weight: 500;
}

.project-points h3 {
  margin: 0 0 var(--space-tight);
  font-family: var(--font-display);
  font-size: var(--type-entry);
  font-weight: 500;
  letter-spacing: var(--track-entry);
  line-height: 1.35;
}

.project-points p + p {
  margin-top: var(--space-stack);
}

.project-points.is-stacked {
  grid-template-columns: minmax(0, 38em);
}

.project-points.is-flow {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.project-points.is-stacked h3 {
  font-size: var(--type-section);
  font-weight: 400;
  letter-spacing: var(--track-section);
  line-height: 1.25;
}

.project-points.is-stacked.is-illustrated {
  grid-template-columns: minmax(0, 1fr);
}

.project-points.is-illustrated > li > :not(figure, .project-aside) {
  max-width: 38em;
}

.project-points .project-aside {
  align-items: start;
}

.project-points .project-aside-copy p + p {
  margin-top: var(--space-stack);
}

.project-compares {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-grid);
  align-items: start;
}

/* Before/after: both exports share a frame, so a clip lines the phones up. */
@property --pos {
  syntax: "<number>";
  inherits: true;
  initial-value: 50;
}

.compare {
  margin: 0;
}

.compare-stage {
  --pos: 50;
  position: relative;
  aspect-ratio: 1022 / 1042;
  overflow: hidden;
  background: #000;
  cursor: ew-resize;
  touch-action: pan-y;
  user-select: none;
  transition: --pos 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.compare-stage.is-dragging {
  transition: none;
}

.compare-stage img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  pointer-events: none;
}

.compare-before {
  clip-path: inset(0 calc((100 - var(--pos)) * 1%) 0 0);
}

.compare-label {
  position: absolute;
  top: 7%;
  z-index: 2;
  margin: 0;
  padding: 6px 12px;
  border: 0;
  border-radius: 8px;
  background: rgba(72, 72, 72, 0.88);
  color: #fff;
  font-family: var(--font-ui);
  font-size: 13px;
  line-height: 1.2;
  cursor: pointer;
}

.compare-label-before {
  left: 4.5%;
}

.compare-label-after {
  right: 4.5%;
}

.compare-label[aria-pressed="true"] {
  background: rgba(255, 255, 255, 0.92);
  color: #1a1a1a;
}

.compare-rule {
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(var(--pos) * 1%);
  z-index: 2;
  width: 1px;
  background: #fff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35);
  transform: translateX(-50%);
  pointer-events: none;
}

.compare-handle {
  position: absolute;
  top: 50%;
  left: clamp(23px, calc(var(--pos) * 1%), calc(100% - 23px));
  z-index: 3;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(32, 32, 32, 0.42);
  color: #fff;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.7), 0 8px 20px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(8px);
  transform: translate(-50%, -50%);
  cursor: ew-resize;
}

.compare-label:focus-visible,
.compare-handle:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  .compare-stage {
    transition: none;
  }
}

/* Lessons sit beside a scrapbook of the people who built Dice. */
.project-lessons {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(17rem, 0.92fr);
  align-items: start;
  column-gap: clamp(28px, 4vw, 64px);
  row-gap: var(--space-block);
}

.project-lessons-copy {
  display: flex;
  flex-direction: column;
  gap: var(--space-block);
  min-width: 0;
}

.project-lessons .project-points.is-stacked {
  grid-template-columns: minmax(0, 1fr);
  margin-top: 0;
}

.team-collage {
  position: relative;
  width: min(100%, 26rem);
  margin: 3.1rem 0 0 auto;
  justify-self: end;
}

.team-note {
  position: relative;
  z-index: 3;
  width: 9.4em;
  margin: 0 0 0 0.35rem;
  color: var(--accent);
  font-family: "Caveat", "Segoe Print", cursive;
  font-size: clamp(30px, 2.5vw, 36px);
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 0.92;
  transform: rotate(-3.5deg);
  transform-origin: left center;
}

.team-amazing {
  position: relative;
  display: inline-block;
  font-size: 1.28em;
  font-weight: 700;
  line-height: 0.8;
}

.team-underline {
  position: absolute;
  left: -4%;
  bottom: -0.22em;
  width: 108%;
  height: 0.42em;
  overflow: visible;
  pointer-events: none;
}

.team-photos {
  position: relative;
  z-index: 1;
  height: 34rem;
  margin-top: 0.85rem;
}

.team-photo {
  position: absolute;
  display: block;
  object-fit: cover;
  border: 6px solid #fff;
  background: #fff;
  box-shadow:
    0 1px 2px color-mix(in srgb, var(--fg) 10%, transparent),
    0 12px 28px color-mix(in srgb, var(--fg) 14%, transparent);
}

.team-photo.is-field {
  top: 0;
  left: 7%;
  width: 90%;
  height: 46%;
  object-position: center 42%;
  transform: rotate(-2.2deg);
  z-index: 1;
}

.team-photo.is-ferry {
  top: 44%;
  left: -3%;
  width: 49%;
  height: 53%;
  object-position: center 24%;
  transform: rotate(1deg);
  z-index: 2;
}

.team-photo.is-steps {
  top: 46%;
  right: 0;
  width: 62%;
  height: 47%;
  object-position: 18% 42%;
  transform: rotate(-2.2deg);
  transform-origin: center center;
  z-index: 4;
}

.project-use-case {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.88fr);
  align-items: start;
  gap: var(--space-grid);
}

.project-use-case-copy {
  display: flex;
  flex-direction: column;
  gap: var(--space-block);
  min-width: 0;
}

.project-use-case .project-points {
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-block);
  margin: 0;
}

.project-use-case .project-media {
  min-width: 0;
  width: 92%;
  margin: 0;
  justify-self: end;
}

.project-use-case .project-media-card {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  height: auto;
}

.project-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
  gap: var(--space-grid);
  margin: var(--space-tight) 0;
}

.project-stats.is-outcome {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.project-stats dt {
  margin: 0 0 var(--space-tight);
  font-family: var(--font-display);
  font-size: var(--type-entry);
  font-weight: 500;
  letter-spacing: var(--track-entry);
  line-height: 1.35;
}

.project-stat-figure {
  display: block;
  margin-bottom: var(--space-tight);
  color: var(--accent);
  font-size: var(--type-project);
  font-weight: 400;
  letter-spacing: var(--track-display);
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.project-stat-name + .project-stat-figure {
  margin-top: var(--space-tight);
  margin-bottom: 0;
}

.project-stats dd {
  max-width: 24em;
  color: var(--fg-muted);
}

/* A moment worth pulling out of the prose */
.project-callout {
  display: flex;
  flex-direction: column;
  gap: var(--space-tight);
  margin: var(--space-tight) 0;
  padding: var(--space-stack) var(--space-block);
  background: var(--wash);
}

.project-callout-link {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 0.28em;
  text-decoration-thickness: 1px;
  text-decoration-color: color-mix(in srgb, var(--accent) 55%, transparent);
}

.project-callout-link:hover {
  text-decoration-color: var(--accent);
}

.project-callout-link:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

.award-moment {
  position: relative;
  margin: 1.15rem 0 0.35rem;
}

.award-note {
  position: relative;
  z-index: 2;
  width: max-content;
  margin: 0 0 0.15rem 0.15rem;
  color: var(--accent);
  font-family: "Caveat", "Segoe Print", cursive;
  font-size: clamp(32px, 2.8vw, 40px);
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 0.92;
  transform: rotate(-3deg);
  transform-origin: left center;
}

.award-moment img {
  display: block;
  width: 100%;
  height: auto;
  margin-top: 0.35rem;
  border: 6px solid #fff;
  background: #fff;
  box-shadow:
    0 1px 2px color-mix(in srgb, var(--fg) 10%, transparent),
    0 10px 24px color-mix(in srgb, var(--fg) 12%, transparent);
}

.project-callout .project-prose {
  max-width: none;
}

.project-callout .project-prose p {
  line-height: 1.5;
}

.project-callout .project-heading {
  margin: 0;
}

.project-callout .project-label + .project-heading {
  margin-top: calc(var(--space-tight) - var(--space-stack));
}

/* Steps: one idea per row, each with its own visual. Rows alternate sides. */
.project-steps {
  display: flex;
  flex-direction: column;
  gap: var(--space-section);
  margin: var(--space-tight) 0;
  padding: 0;
  list-style: none;
}

.project-steps > li {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  align-items: center;
  gap: var(--space-grid);
}

.project-steps > li:nth-child(even) {
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
}

.project-steps > li:nth-child(even) > .project-step-text {
  order: 2;
}

.project-steps.is-start > li:nth-child(even) {
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
}

.project-steps.is-start > li:nth-child(even) > .project-step-text {
  order: 0;
}

.project-steps.is-stack > li,
.project-steps.is-stack > li:nth-child(even),
.project-steps.is-stack.is-start > li:nth-child(even) {
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
}

.project-steps.is-stack > li:nth-child(even) > .project-step-text {
  order: 0;
}

.project-steps.is-stack .project-step-text p {
  max-width: 38em;
}

.project-steps.is-stack .project-media {
  width: min(100%, 38em);
}

.project-media.is-compare {
  position: relative;
}

.project-media-arrow {
  position: absolute;
  top: 58%;
  left: 50%;
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  color: var(--fg);
  pointer-events: none;
  transform: translate(-50%, -50%);
  animation: media-arrow 1.4s ease-in-out infinite;
}

.project-media-arrow svg {
  width: 100%;
  height: 100%;
}

@media (max-width: 720px) {
  .project-media-arrow {
    width: 1.4rem;
    height: 1.4rem;
  }
}

@keyframes media-arrow {
  0%,
  100% {
    transform: translate(-50%, -70%);
  }

  50% {
    transform: translate(-50%, -30%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .project-media-arrow {
    animation: none;
  }
}

.project-steps .project-media {
  margin: 0;
}

.project-step-text .project-index {
  display: block;
  margin-bottom: var(--space-tight);
  color: var(--accent);
  font-family: var(--font-ui);
  font-size: var(--type-meta);
  font-weight: 500;
}

.project-step-text h3 {
  margin: 0 0 var(--space-tight);
  font-family: var(--font-display);
  font-size: var(--type-section);
  font-weight: 400;
  letter-spacing: var(--track-section);
  line-height: 1.25;
}

.project-step-text p {
  margin: 0;
  max-width: 26em;
  font-family: var(--font-text);
  font-size: var(--type-body);
  letter-spacing: var(--track-body);
  line-height: 1.65;
}

.project-step-text p + p {
  margin-top: var(--space-stack);
}

.project-step-text strong {
  font-weight: 600;
}

/* The closing line of a case study */
.project-quote {
  margin: 0;
  padding-left: var(--space-grid);
  border-left: 2px solid var(--accent);
}

.project-quote p {
  margin: 0;
  max-width: 20em;
  font-family: var(--font-display);
  font-size: var(--type-section);
  font-weight: 400;
  letter-spacing: var(--track-section);
  line-height: 1.3;
  text-wrap: balance;
}

.project-hmw {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-stack);
}

.project-hmw p.project-label {
  max-width: none;
  margin: 0;
  font-family: var(--font-ui);
  font-size: var(--type-meta);
  font-weight: 500;
  letter-spacing: var(--track-chrome);
  line-height: 1.4;
  text-transform: uppercase;
  color: var(--accent);
}

.project-years {
  display: flex;
  flex-direction: column;
  gap: var(--space-stack);
  width: min(100%, 720px);
  margin: var(--space-tight) 0;
}

.project-year-tabs {
  --year: 0;
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-self: start;
  width: min(100%, 22rem);
}

.project-year-thumb {
  position: absolute;
  inset: 0 auto 0 0;
  width: calc(100% / 3);
  background: var(--accent);
  border-radius: 999px;
  transform: translateX(calc(var(--year) * 100%));
  transition: transform 0.28s ease;
}

.project-year {
  position: relative;
  z-index: 1;
  margin: 0;
  padding: 10px 12px;
  border: 0;
  background: none;
  color: var(--fg-muted);
  font-family: var(--font-ui);
  font-size: var(--type-label);
  font-weight: 500;
  letter-spacing: var(--track-chrome);
  line-height: 1.4;
  cursor: pointer;
}

.project-year:hover {
  color: var(--fg);
}

.project-year[aria-selected="true"],
.project-year[aria-selected="true"]:hover {
  color: var(--bg);
}

.project-year:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

.project-year-stage {
  position: relative;
  aspect-ratio: 2794 / 1554;
  background: #1b1b1b;
}

.project-year-stage [role="tabpanel"] {
  position: absolute;
  inset: 0;
}

.project-year-stage [role="tabpanel"][hidden] {
  display: none;
}

.project-year-stage img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-follow {
  display: flex;
  flex-direction: column;
  gap: var(--space-block);
}

.project-aside + .project-follow,
.project-compares + .project-follow {
  margin-top: var(--space-grid);
}

.project-follow .project-heading {
  margin-top: 0;
}

/* Same 8px a step or aside title keeps above its copy. Quotes and figures stay a full block away. */
.project-follow .project-heading + :not(.project-quotes, .project-media) {
  margin-top: calc(var(--space-tight) - var(--space-block));
}

.project-follow .project-media {
  margin: 0;
}

.project-quote figcaption {
  margin-top: var(--space-stack);
  max-width: 32em;
  color: var(--fg-muted);
  font-family: var(--font-text);
  font-size: var(--type-body);
  line-height: 1.6;
}

.project-quotes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-grid);
  margin: 0;
}

.project-quotes .project-quote p {
  max-width: none;
  font-size: var(--type-entry);
  letter-spacing: var(--track-entry);
  line-height: 1.45;
}

.project-back {
  display: inline-flex;
  align-items: baseline;
  gap: var(--space-tight);
  margin: 0 0 var(--space-block);
  color: var(--fg-muted);
  font-family: var(--font-ui);
  font-size: var(--type-chrome);
  font-weight: 500;
  letter-spacing: var(--track-chrome);
  line-height: 1.4;
  text-transform: uppercase;
}

.project-back:hover {
  color: var(--fg);
}

.project-back:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

.project-pager {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: end;
  gap: var(--space-grid);
  margin-top: var(--space-section);
  padding-top: var(--space-grid);
  border-top: 1px solid var(--border);
}

.project-pager-link {
  display: flex;
  flex-direction: column;
  gap: var(--space-tight);
  width: max-content;
  max-width: 100%;
  min-width: 0;
}

.project-pager-prev {
  grid-column: 1;
  justify-self: start;
  text-align: left;
}

.project-pager-next {
  grid-column: 3;
  justify-self: end;
  text-align: right;
}

.project-pager-kicker,
.project-top {
  color: var(--fg-muted);
  font-family: var(--font-ui);
  font-size: var(--type-chrome);
  font-weight: 500;
  letter-spacing: var(--track-chrome);
  line-height: 1.4;
  text-transform: uppercase;
}

.project-pager .project-top {
  grid-column: 2;
  padding-bottom: 0.2em;
}

.project-top:hover {
  color: var(--fg);
}

.project-pager-title {
  font-family: var(--font-display);
  font-size: var(--type-entry);
  font-weight: 500;
  letter-spacing: var(--track-entry);
  line-height: 1.35;
}

.project-pager-link:hover {
  color: var(--fg-muted);
}

.project-pager-link:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

@media (max-width: 960px) {
  .project-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .project-summary,
  .project-summary.is-pair,
  .project-aside,
  .project-points,
  .project-points.is-flow,
  .project-media-pair,
  .project-compares,
  .project-quotes,
  .project-use-case,
  .project-lessons {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-block);
  }

  .project-aside.is-flip > .project-aside-copy {
    order: 0;
  }

  .team-collage {
    width: min(100%, 28rem);
    margin-top: var(--space-tight);
  }

  .team-photos {
    height: 30rem;
  }

  .project-use-case .project-media {
    width: 100%;
    justify-self: stretch;
  }

  .project-summary.is-challenges,
  .project-stats.is-outcome {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .foundations-board {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .project-media-card.is-inset {
    aspect-ratio: auto;
    min-height: 16rem;
  }

  .token-map li,
  .project-media-card .token-map li {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }

  .token-map li > span {
    text-align: left;
  }

  .token-map-example,
  .project-media-card .token-map-example {
    padding-left: 0;
  }

  .project-callout {
    padding: 14px var(--space-stack);
  }

  .project-body,
  .project-lock-body {
    gap: var(--space-section);
  }

  .project-steps {
    gap: var(--space-grid);
  }

  .project-steps > li,
  .project-steps > li:nth-child(even),
  .project-steps.is-start > li:nth-child(even),
  .project-steps.is-stack > li,
  .project-steps.is-stack > li:nth-child(even) {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-block);
  }

  .project-steps > li:nth-child(even) > .project-step-text {
    order: 0;
  }

  .project-quote {
    padding-left: var(--space-block);
  }

  .project-pager {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: start;
    gap: 12px;
  }

  .project-pager-link {
    width: 100%;
    gap: 4px;
  }

  .project-pager-prev {
    grid-column: 1;
    justify-self: start;
    text-align: left;
  }

  .project-pager-next {
    grid-column: 3;
    justify-self: end;
    text-align: right;
  }

  .project-pager .project-top {
    grid-column: 2;
    justify-self: center;
    margin-top: 0;
    padding-bottom: 0;
    text-align: center;
    white-space: nowrap;
  }

  .project-pager-kicker,
  .project-pager .project-top {
    font-size: 11px;
  }

  .project-pager-title {
    font-size: 14px;
    line-height: 1.25;
  }
}

@media (prefers-reduced-motion: reduce) {
  .project-toc a {
    transition: none;
  }
}

.project-lock {
  position: relative;
}

.project-lock-body {
  display: flex;
  flex-direction: column;
  gap: calc(var(--space-section) * 1.5);
}

.project-lock.is-locked {
  min-height: 420px;
}

.project-lock.is-locked .project-lock-body {
  max-height: 420px;
  overflow: hidden;
  pointer-events: none;
  user-select: none;
  mask-image: linear-gradient(to bottom, #000 48%, transparent);
  -webkit-mask-image: linear-gradient(to bottom, #000 48%, transparent);
}

.project-lock.is-locked .project-lock-body > * {
  filter: blur(18px);
}

.project-lock.is-locked::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    color-mix(in srgb, var(--bg) 22%, transparent) 45%,
    color-mix(in srgb, var(--bg) 52%, transparent) 100%
  );
  pointer-events: none;
}

.project-lock-panel {
  display: none;
}

.project-lock.is-locked .project-lock-panel {
  display: flex;
  position: absolute;
  inset: 0;
  z-index: 1;
  align-items: center;
  justify-content: center;
  padding: var(--space-block);
}

.project-gate {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-block);
  width: min(28em, 100%);
  text-align: center;
}

.project-gate-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-stack);
}

.project-gate-copy {
  margin: 0;
  max-width: 22em;
  font-family: var(--font-display);
  font-size: var(--type-entry);
  font-weight: 400;
  letter-spacing: var(--track-entry);
  line-height: 1.4;
  text-wrap: pretty;
}

.project-gate-note {
  margin: 0;
  max-width: 22em;
  color: var(--fg-muted);
  font-family: var(--font-text);
  font-size: var(--type-body);
  font-weight: 400;
  letter-spacing: var(--track-body);
  line-height: 1.5;
  text-wrap: pretty;
}

.project-gate-link {
  color: var(--fg);
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
  text-decoration-color: color-mix(in srgb, var(--fg) 55%, transparent);
}

.project-gate-link:hover {
  color: var(--fg-muted);
}

.project-gate-link:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

.project-gate-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.project-gate-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-stack);
  width: 100%;
}

.project-gate-row {
  display: flex;
  align-items: center;
  flex: 1 1 auto;
  min-width: 0;
  padding: 4px 6px 4px 18px;
  border: 0;
  border-radius: 999px;
  background: color-mix(in srgb, var(--fg) 8%, var(--bg));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--fg) 12%, transparent);
}

.project-gate input {
  flex: 1 1 auto;
  min-width: 0;
  height: 42px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  appearance: none;
  -webkit-appearance: none;
  color: var(--fg);
  font-family: var(--font-ui);
  font-size: var(--type-label);
  font-weight: 400;
  letter-spacing: var(--track-body);
}

.project-gate input::placeholder {
  color: var(--fg-muted);
  opacity: 1;
}

.project-gate input:focus-visible {
  outline: none;
}

.project-gate-eye {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 40px;
  height: 42px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--fg-muted);
}

.project-gate-eye svg {
  display: block;
}

.project-gate-row:focus-within {
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--fg) 28%, transparent);
}

.project-gate-eye[aria-pressed="true"] .eye-slash {
  display: none;
}

.project-gate-eye:hover,
.project-gate-eye[aria-pressed="true"] {
  color: var(--fg);
}

.project-gate-unlock {
  flex: 0 0 auto;
  height: 42px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--fg);
  font-family: var(--font-ui);
  font-size: var(--type-chrome);
  font-weight: 500;
  letter-spacing: var(--track-chrome);
  line-height: 1;
  text-transform: uppercase;
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
  text-decoration-color: color-mix(in srgb, var(--fg) 55%, transparent);
}

.project-gate-unlock:hover {
  color: var(--fg-muted);
}

.project-gate-eye:focus-visible,
.project-gate-unlock:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

.project-gate-error {
  margin: 0;
  color: var(--fg-muted);
  font-family: var(--font-ui);
  font-size: var(--type-meta);
  font-weight: 400;
  letter-spacing: var(--track-meta);
  line-height: 1.5;
}

html.gate-open .project-lock.is-locked {
  min-height: 0;
}

html.gate-open .project-lock.is-locked .project-lock-body {
  max-height: none;
  overflow: visible;
  pointer-events: auto;
  user-select: auto;
  mask-image: none;
  -webkit-mask-image: none;
}

html.gate-open .project-lock.is-locked .project-lock-body > * {
  filter: none;
}

html.gate-open .project-lock.is-locked::after,
html.gate-open .project-lock.is-locked .project-lock-panel {
  display: none;
}

@media (prefers-reduced-motion: reduce) {
  .project-lock.is-locked .project-lock-body > * {
    filter: none;
    opacity: 0.28;
  }
}

.v2-changes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-block) var(--space-stack);
  margin: 0;
  padding: 0;
  list-style: none;
}

.v2-changes > li {
  display: flex;
  flex-direction: column;
  gap: var(--space-tight);
  min-width: 0;
}

.v2-changes-title {
  margin: 0;
  color: var(--fg-muted);
  font-family: var(--font-ui);
  font-size: var(--type-meta);
  font-weight: 500;
  letter-spacing: var(--track-chrome);
  line-height: 1.4;
  text-transform: uppercase;
}

.v2-changes > li > p:not(.v2-changes-title) {
  margin: 0;
  font-family: var(--font-text);
  font-size: var(--type-body);
  line-height: 1.55;
}

.v2-changes > li > img,
.v2-changes > li > .audit-frame,
.v2-changes-shots {
  width: 100%;
}

.v2-changes img {
  display: block;
  width: 100%;
  height: auto;
  background: var(--fill);
  box-shadow: inset 0 0 0 1px var(--border);
}

.v2-changes-shots {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  align-items: start;
}

.v2-changes-shots figure {
  margin: 0;
}

@media (max-width: 720px) {
  .v2-changes {
    grid-template-columns: 1fr;
  }
}

.pasture {
  display: block;
  width: 100%;
}

.page-pasture {
  padding: 0 var(--chrome-gutter);
}

.pasture-home {
  height: calc(100vh - (2 * var(--bar-height)));
  min-height: 480px;
}

.footer {
  background: var(--bg);
}

.footer-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--bar-height);
  padding: 0 var(--chrome-gutter);
  background: var(--bg);
}

.footer-label {
  color: var(--fg-muted);
}

.footer-links {
  display: flex;
  align-items: center;
  gap: var(--space-block);
}

.footer-links a {
  display: flex;
  color: var(--fg-muted);
  transition: color 0.2s ease;
}

.footer-links svg {
  display: block;
}

.footer-links a:hover,
.footer-links a:focus-visible {
  color: var(--fg);
}

.footer-links a:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

/* Manual V1 → V2 swap. The Sportsbook button stays put. Only the panel changes. */
.manual-swap.project-media-frame {
  display: block;
  aspect-ratio: auto;
  height: auto;
  padding: 36px 28px;
  overflow: hidden;
  background: var(--card);
  color: #1c1c1c;
  font-family: Inter, "Helvetica Neue", system-ui, sans-serif;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.3;
  text-align: left;
  container-type: inline-size;
}

.manual-swap-layout {
  display: flex;
  align-items: center;
  justify-content: center;
  justify-self: stretch;
  width: 100%;
  gap: 52px;
}

.manual-screen-wrap {
  width: 268px;
  flex: none;
}

.manual-phone {
  overflow: hidden;
  border-radius: 28px;
  background: #0c0c0c;
  line-height: 0;
  box-shadow: 0 18px 40px rgba(20, 24, 28, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.38);
}

.manual-phone img {
  display: block;
  width: 100%;
  height: auto;
}

.manual-stack {
  display: grid;
}

.manual-stack > span {
  grid-area: 1 / 1;
  transition: opacity 0.28s ease;
}

.manual-stack .is-v2 {
  opacity: 0;
}

.manual-swap[data-panel="v2"] .manual-panel .is-v1 {
  opacity: 0;
}

.manual-swap[data-panel="v2"] .manual-panel .is-v2 {
  opacity: 1;
}

.manual-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 348px;
  flex: none;
  overflow: hidden;
  border-radius: 12px;
  background: #2c2c2c;
  color: #f3f3f3;
  box-shadow: 0 16px 36px rgba(20, 24, 28, 0.14), 0 0 0 1px rgba(0, 0, 0, 0.28);
}

.manual-panel svg {
  display: block;
  flex: none;
}

.manual-panel-head {
  display: flex;
  flex: none;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  padding: 14px 8px 10px 14px;
}

.manual-panel-id {
  min-width: 0;
}

.manual-comp,
.manual-lib {
  white-space: nowrap;
}

.manual-comp {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
}

.manual-lib {
  display: flex;
  align-items: center;
  gap: 5px;
  margin: 3px 0 0;
  color: #a3a3a3;
  font-size: 11px;
  font-weight: 400;
}

.manual-panel-tools {
  display: flex;
  flex: none;
  gap: 0;
  color: #d4d4d4;
}

.manual-swap-icon,
.manual-grid-icon,
.manual-more-icon,
.manual-mini {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 6px;
  color: #d6d6d6;
}

.manual-swap-icon {
  transition: background 0.15s ease;
}

.manual-swap[data-hot="swap"] .manual-swap-icon {
  background: rgba(255, 255, 255, 0.12);
}

.manual-panel-body {
  position: relative;
}

.manual-menu-clip {
  position: absolute;
  z-index: 2;
  top: 0;
  right: 8px;
  left: 8px;
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  pointer-events: none;
  transition: grid-template-rows 0.34s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.22s ease;
}

.manual-swap[data-open] .manual-menu-clip {
  grid-template-rows: 1fr;
  opacity: 1;
}

.manual-menu-fold {
  min-height: 0;
  overflow: hidden;
}

.manual-menu {
  padding: 4px 4px 8px;
  border-radius: 8px;
  background: #2c2c2c;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.manual-menu-top,
.manual-crumb,
.manual-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 28px;
  padding: 0 8px;
  font-size: 12px;
}

.manual-menu-top {
  justify-content: space-between;
  min-height: 32px;
  color: #fff;
  font-weight: 650;
}

.manual-menu-top span:last-child {
  color: #cfcfcf;
  font-size: 16px;
  font-weight: 400;
  line-height: 1;
}

.manual-search {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 32px;
  margin: 2px 6px 8px;
  padding: 0 8px;
  border: 1.5px solid #0d99ff;
  border-radius: 6px;
  color: #8f8f8f;
  font-size: 12px;
}

.manual-source-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 6px 4px;
}

.manual-source {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: space-between;
  min-width: 0;
  height: 32px;
  padding: 0 8px;
  border-radius: 6px;
  color: #f2f2f2;
  font-size: 12px;
  box-shadow: inset 0 0 0 1px #555;
}

.manual-source span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.manual-crumb {
  color: #d0d0d0;
}

.manual-rows {
  margin: 2px 0 0;
  padding: 0;
  list-style: none;
}

.manual-row {
  min-height: 44px;
  border-radius: 6px;
  color: #f5f5f5;
  transition: background 0.15s ease;
}

.manual-swap[data-hot="row"] .manual-row.is-target {
  background: rgba(255, 255, 255, 0.08);
}

.manual-thumb {
  display: grid;
  flex: none;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.06);
}

.manual-thumb-text span,
.manual-thumb-bonus span,
.manual-thumb-empty span {
  display: block;
}

.manual-thumb-text span {
  padding: 3px 3px 2px;
  border-radius: 3px;
  background: #7b61ff;
  color: #fff;
  font-size: 6px;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.manual-thumb-bonus span,
.manual-thumb-empty span {
  width: 24px;
  border: 1px solid #c5c5c5;
  border-radius: 3px;
}

.manual-thumb-bonus span {
  padding: 2px 1px 1px;
  color: #666;
  font-size: 5px;
  font-weight: 600;
  line-height: 1.15;
  text-align: center;
}

.manual-thumb-empty span {
  height: 14px;
}

.manual-thumb-icon {
  background: #fff;
}

.manual-thumb-icon svg {
  width: 22px;
  height: 22px;
  padding: 4px;
  border-radius: 4px;
  background: #7b61ff;
  box-sizing: border-box;
}

.manual-thumb-icon.is-inverse svg {
  background: #6d28d9;
}

.manual-props {
  padding: 2px 12px 16px;
}

.manual-sec {
  padding: 10px 0 12px;
}

.manual-sec + .manual-sec {
  border-top: 1px solid #3d3d3d;
}

.manual-sec h3,
.manual-sec-head {
  margin: 0;
}

.manual-sec h3 {
  color: #fff;
  font-size: 12px;
  font-weight: 650;
}

.manual-sec-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.manual-sec-tools {
  display: flex;
  gap: 8px;
  color: #bdbdbd;
}

.manual-k {
  margin: 8px 0 4px;
  color: #a3a3a3;
  font-size: 11px;
}

.manual-flow,
.manual-resize,
.manual-gap-controls,
.manual-pair,
.manual-pad {
  display: flex;
  align-items: center;
  gap: 6px;
}

.manual-seg {
  display: flex;
  flex: 1;
  height: 28px;
  padding: 2px;
  border-radius: 6px;
  background: #383838;
}

.manual-seg span,
.manual-mini {
  color: #cfcfcf;
}

.manual-seg span {
  display: grid;
  flex: 1;
  place-items: center;
  border-radius: 4px;
}

.manual-seg span.is-on {
  background: #4a4a4a;
  color: #fff;
}

.manual-input {
  display: flex;
  flex: 1;
  align-items: center;
  gap: 6px;
  min-width: 0;
  height: 28px;
  padding: 0 8px;
  border-radius: 5px;
  background: #383838;
  color: #f3f3f3;
  font-size: 11px;
}

.manual-input b {
  color: #9a9a9a;
  font-weight: 500;
}

.manual-input svg:last-child:not(:first-child) {
  margin-left: auto;
  color: #bdbdbd;
}

.manual-resize .manual-mini,
.manual-gap-controls .manual-mini,
.manual-source-row .manual-mini {
  background: #383838;
}

.manual-align-row {
  display: flex;
  gap: 10px;
  margin-top: 2px;
}

.manual-align-row > div:first-child {
  flex: none;
}

.manual-gap {
  flex: 1;
  min-width: 0;
}

.manual-align {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: 108px;
  height: 68px;
  padding: 8px;
  border-radius: 6px;
  background: #383838;
}

.manual-align i {
  width: 3px;
  height: 3px;
  margin: auto;
  border-radius: 50%;
  background: #6a6a6a;
}

.manual-align i.is-on {
  width: 16px;
  height: 14px;
  border-radius: 0;
  background: transparent;
}

.manual-align i.is-on::before {
  content: "";
  display: block;
  width: 2px;
  height: 12px;
  margin: 1px auto 0;
  border-radius: 1px;
  background: #0d99ff;
  box-shadow: -5px 0 0 #0d99ff, 5px 0 0 #0d99ff;
}

.manual-pad {
  display: grid;
  grid-template-columns: 1fr 1fr 28px;
  gap: 6px;
}

.manual-pad-toggle {
  display: grid;
  grid-row: 1 / span 2;
  grid-column: 3;
  width: 28px;
  height: 62px;
  place-items: center;
  border-radius: 6px;
  color: #0d99ff;
  box-shadow: inset 0 0 0 1.5px #0d99ff;
}

.manual-check {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 10px 0 0;
  color: #d0d0d0;
  font-size: 11px;
}

.manual-check i {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  box-shadow: inset 0 0 0 1.2px #8a8a8a;
}

.manual-pair {
  align-items: flex-end;
}

.manual-pair > div {
  flex: 1;
  min-width: 0;
}

.manual-chip-row {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 28px;
  margin-top: 8px;
  padding: 0 6px 0 8px;
  border-radius: 5px;
  background: #383838;
  color: #ececec;
  font-size: 10px;
}

.manual-chip-row span {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.manual-chip-row svg {
  color: #c8c8c8;
}

.manual-swatch {
  width: 14px;
  height: 14px;
  flex: none;
  border-radius: 2px;
  background: conic-gradient(#d0d0d0 25%, #fff 0 50%, #d0d0d0 0 75%, #fff 0) 0 0 / 7px 7px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.25);
}

.manual-cursor {
  position: absolute;
  z-index: 4;
  top: 0;
  left: 0;
  opacity: 0;
  pointer-events: none;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.35));
}

.manual-cursor svg {
  display: block;
  transform-origin: 3px 2px;
  transition: transform 0.12s ease;
}

.manual-swap[data-ready] .manual-cursor {
  opacity: 1;
  transition: transform 0.65s cubic-bezier(0.45, 0.05, 0.25, 1), opacity 0.2s linear;
}

.manual-swap[data-press] .manual-cursor svg {
  transform: scale(0.86);
}

@container (max-width: 680px) {
  .manual-swap.project-media-frame {
    padding: 24px 16px;
  }

  .manual-swap-layout {
    flex-direction: column;
    gap: 28px;
  }

  .manual-screen-wrap,
  .manual-panel {
    width: min(348px, 100%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .manual-swap,
  .manual-swap * {
    transition: none !important;
  }
}

/* Bulk swap. Sportsbook on the left, plugin on the right. */
.bulk-swap.project-media-frame {
  display: block;
  aspect-ratio: auto;
  height: auto;
  padding: 36px 28px;
  overflow: hidden;
  background: var(--card);
  color: #1c1c1c;
  font-family: Inter, "Helvetica Neue", system-ui, sans-serif;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.3;
  text-align: left;
  container-type: inline-size;
}

.bulk-swap-layout {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  gap: 52px;
}

.bulk-screen {
  width: 268px;
  flex: none;
}

.bulk-phone {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #0c0c0c;
  line-height: 0;
  box-shadow: 0 18px 40px rgba(20, 24, 28, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.38);
}

.bulk-phone img {
  display: block;
  width: 100%;
  height: auto;
}

.bulk-beam {
  position: absolute;
  left: 0;
  right: 0;
  height: 22%;
  top: -22%;
  background: linear-gradient(to bottom, transparent, rgba(75, 163, 226, 0.42), transparent);
  opacity: 0;
  pointer-events: none;
}

.bulk-swap[data-phase="scan"] .bulk-beam {
  opacity: 1;
  animation: bulk-beam 1.7s linear forwards;
}

@keyframes bulk-beam {
  from { top: -22%; }
  to { top: 100%; }
}

.bulk-hit {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: var(--w);
  height: var(--h);
  border-radius: 8px;
  box-shadow: 0 0 0 2px #4ba3e2;
  background: rgba(75, 163, 226, 0.22);
  opacity: 0;
  transform: scale(0.94);
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
  transition-delay: var(--d, 0s);
}

.bulk-hit.is-pill,
.bulk-hit.is-circle {
  border-radius: 999px;
}

.bulk-swap[data-show~="header"] .bulk-hit[data-group="header"],
.bulk-swap[data-show~="odds"] .bulk-hit[data-group="odds"],
.bulk-swap[data-show~="actions"] .bulk-hit[data-group="actions"] {
  opacity: 1;
  transform: none;
}

.bulk-swap[data-swapped] .bulk-hit {
  animation: bulk-flash 0.55s ease forwards;
}

@keyframes bulk-flash {
  0% { box-shadow: 0 0 0 2px #fff; background: rgba(255, 255, 255, 0.34); }
  100% { box-shadow: 0 0 0 2px #3dbe7a; background: rgba(61, 190, 122, 0.24); }
}

.bulk-plugin {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 320px;
  flex: none;
  overflow: hidden;
  border-radius: 12px;
  background: #fff;
  color: #1c1c1c;
  box-shadow: 0 16px 36px rgba(20, 24, 28, 0.14), 0 0 0 1px rgba(0, 0, 0, 0.18);
}

.bulk-plugin-bar {
  display: flex;
  flex: none;
  align-items: center;
  gap: 8px;
  height: 42px;
  padding: 0 12px;
  background: #2c2c2c;
  color: #fff;
}

.bulk-plugin-bar p {
  flex: 1;
  margin: 0;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  text-align: center;
}

.bulk-plugin-mark,
.bulk-plugin-x {
  display: grid;
  width: 18px;
  flex: none;
  place-items: center;
}

.bulk-plugin-x {
  color: #fff;
  font-size: 16px;
  line-height: 1;
}

.bulk-plugin-body {
  position: relative;
  padding: 14px 14px 16px;
}

.bulk-scan,
.bulk-go {
  display: grid;
  place-items: center;
  height: 34px;
  margin: 0;
  border-radius: 6px;
  background: #4ba3e2;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
}

.bulk-scan .is-busy,
.bulk-swap[data-phase="scan"] .bulk-scan .is-idle {
  display: none;
}

.bulk-swap[data-phase="scan"] .bulk-scan .is-busy {
  display: inline;
}

.bulk-swap[data-hot="scan"] .bulk-scan,
.bulk-swap[data-hot="swap"] .bulk-go {
  filter: brightness(0.92);
}

.bulk-swap[data-results] .bulk-scan {
  background: #fff;
  color: #334155;
  box-shadow: inset 0 0 0 1px #e2e8f0;
  filter: none;
}

.bulk-results {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  transition: grid-template-rows 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.25s ease;
}

.bulk-swap[data-results] .bulk-results {
  grid-template-rows: 1fr;
  opacity: 1;
}

.bulk-results-fold {
  min-height: 0;
  overflow: hidden;
}

.bulk-kicker {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 14px 2px 8px;
  color: #94a3b8;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.bulk-count {
  display: grid;
  min-width: 22px;
  height: 18px;
  place-items: center;
  padding: 0 6px;
  border-radius: 999px;
  background: #e8f4fc;
  color: #1d6f9c;
  font-size: 11px;
  letter-spacing: 0;
}

.bulk-swap[data-swapped] .bulk-count {
  background: #e5f6ec;
  color: #1d7a45;
}

.bulk-stack,
.bulk-to {
  display: grid;
}

.bulk-stack > span,
.bulk-to > span {
  grid-area: 1 / 1;
  transition: opacity 0.25s ease;
}

.bulk-stack .is-v2,
.bulk-to .is-v2 {
  opacity: 0;
}

.bulk-swap[data-swapped] .is-v1 {
  opacity: 0;
}

.bulk-swap[data-swapped] .is-v2 {
  opacity: 1;
}

.bulk-rows {
  margin: 0;
  padding: 0;
  list-style: none;
  border: 1px solid #e6e8ee;
  border-radius: 8px;
}

.bulk-row {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  transition: grid-template-rows 0.32s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.25s ease;
}

.bulk-swap[data-show~="header"] .bulk-row[data-group="header"],
.bulk-swap[data-show~="odds"] .bulk-row[data-group="odds"],
.bulk-swap[data-show~="actions"] .bulk-row[data-group="actions"] {
  grid-template-rows: 1fr;
  opacity: 1;
}

.bulk-row + .bulk-row .bulk-row-inner {
  box-shadow: inset 0 1px 0 #eef0f4;
}

.bulk-row-inner {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 0;
  overflow: hidden;
  padding: 0 10px;
  color: #1c1c1c;
  font-size: 12px;
}

.bulk-swap[data-show~="header"] .bulk-row[data-group="header"] .bulk-row-inner,
.bulk-swap[data-show~="odds"] .bulk-row[data-group="odds"] .bulk-row-inner,
.bulk-swap[data-show~="actions"] .bulk-row[data-group="actions"] .bulk-row-inner {
  min-height: 34px;
}

.bulk-row-inner > span:nth-child(2) {
  flex: 1;
  min-width: 0;
}

.bulk-row b {
  margin-left: 4px;
  color: #64748b;
  font-weight: 600;
}

.bulk-to {
  color: #94a3b8;
  font-size: 11px;
  font-weight: 600;
}

.bulk-to .is-v2 {
  color: #1d7a45;
}

.bulk-check {
  width: 14px;
  height: 14px;
  flex: none;
  border-radius: 4px;
  box-shadow: inset 0 0 0 1.4px #c5c8d0;
}

.bulk-check::after {
  content: "";
  display: block;
  width: 8px;
  height: 5px;
  margin: 3px 0 0 2px;
  border-bottom: 1.6px solid transparent;
  border-left: 1.6px solid transparent;
  transform: rotate(-45deg);
}

.bulk-swap[data-show~="header"] .bulk-row[data-group="header"] .bulk-check,
.bulk-swap[data-show~="odds"] .bulk-row[data-group="odds"] .bulk-check,
.bulk-swap[data-show~="actions"] .bulk-row[data-group="actions"] .bulk-check {
  background: #4ba3e2;
  box-shadow: none;
}

.bulk-swap[data-show~="header"] .bulk-row[data-group="header"] .bulk-check::after,
.bulk-swap[data-show~="odds"] .bulk-row[data-group="odds"] .bulk-check::after,
.bulk-swap[data-show~="actions"] .bulk-row[data-group="actions"] .bulk-check::after {
  border-color: #fff;
}

.bulk-swap[data-swapped] .bulk-check {
  background: #3dbe7a;
}

.bulk-go {
  margin-top: 12px;
  opacity: 0.4;
  transition: opacity 0.25s ease, filter 0.15s ease;
}

.bulk-swap[data-show~="actions"] .bulk-go {
  opacity: 1;
}

.bulk-swap[data-swapped] .bulk-go {
  background: #1d7a45;
}

.bulk-cursor {
  position: absolute;
  z-index: 4;
  top: 0;
  left: 0;
  opacity: 0;
  pointer-events: none;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.35));
}

.bulk-cursor svg {
  display: block;
  transform-origin: 3px 2px;
  transition: transform 0.12s ease;
}

.bulk-swap[data-ready] .bulk-cursor {
  opacity: 1;
  transition: transform 0.65s cubic-bezier(0.45, 0.05, 0.25, 1), opacity 0.2s linear;
}

.bulk-swap[data-press] .bulk-cursor svg {
  transform: scale(0.86);
}

@container (max-width: 680px) {
  .bulk-swap.project-media-frame {
    padding: 24px 16px;
  }

  .bulk-swap-layout {
    flex-direction: column;
    gap: 28px;
  }

  .bulk-screen,
  .bulk-plugin {
    width: min(320px, 100%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .bulk-swap,
  .bulk-swap * {
    transition: none !important;
    animation: none !important;
  }
}
