/* ============================================================================
 * building-float.css — Building With as one scrolling wall
 * ---------------------------------------------------------------------------
 * Three flex rows inside a marquee belt. Flex avoids legacy grid rules that
 * forced a 4-column checkerboard and clipped the marks.
 * ========================================================================== */

#building .stack-carousel {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  height: 300px !important;
  min-height: 300px !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  overflow: hidden !important;
  transform: none !important;
  -webkit-mask-image: linear-gradient(
    90deg,
    transparent 0,
    #000 18px,
    #000 calc(100% - 18px),
    transparent 100%
  ) !important;
  mask-image: linear-gradient(
    90deg,
    transparent 0,
    #000 18px,
    #000 calc(100% - 18px),
    transparent 100%
  ) !important;
}

#building .stack-track {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  height: 300px !important;
  min-height: 300px !important;
  overflow: hidden !important;
  transform: none !important;
  -webkit-mask-image: none !important;
  mask-image: none !important;
}

#building .stack-marquee {
  display: flex !important;
  flex-wrap: nowrap !important;
  align-items: stretch !important;
  width: max-content !important;
  height: 300px !important;
  animation: building-marquee var(--marquee-duration, 52s) linear infinite !important;
}

#building .stack-wall {
  --stack-cell: 96px;
  --stack-gap-x: 24px;
  --stack-stagger: calc((var(--stack-cell) + var(--stack-gap-x)) / 2);

  display: flex !important;
  flex-direction: column !important;
  justify-content: space-between !important;
  gap: 10px !important;
  width: max-content !important;
  height: 300px !important;
  margin: 0 !important;
  padding: 3px 0 !important;
  border: 0 !important;
  background: none !important;
  box-shadow: none !important;
  list-style: none !important;
}

#building .stack-wall__row {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  gap: var(--stack-gap-x) !important;
  width: max-content !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: none !important;
  box-shadow: none !important;
  list-style: none !important;
  overflow: visible !important;
}

/* Logo checkerboard: offset rows 1 & 3 so the middle row sits in the gaps.
   nth-of-type — not nth-child — because whitespace text nodes sit between the rows. */
#building .stack-wall__row:nth-of-type(1),
#building .stack-wall__row:nth-of-type(3) {
  transform: translate3d(var(--stack-stagger, 60px), 0, 0) !important;
}

#building .stack-wall__row:nth-of-type(2) {
  transform: none !important;
}

#building .stack-wall__row > li {
  position: relative !important;
  display: grid !important;
  place-items: center !important;
  flex: 0 0 var(--stack-cell) !important;
  width: var(--stack-cell) !important;
  height: var(--stack-cell) !important;
  margin: 0 !important;
  padding: 4px !important;
  border: 0 !important;
  background: none !important;
  box-shadow: none !important;
  overflow: visible !important;
  animation: none !important;
  cursor: default !important;
  pointer-events: auto !important;
}

#building .stack-wall__row > li::after {
  content: none !important;
}

#building .stack-wall__row > li img,
#building .stack-wall__row > li[data-ink="mono"] img {
  display: block !important;
  width: 68px !important;
  height: 68px !important;
  max-width: 68px !important;
  max-height: 68px !important;
  object-fit: contain !important;
  margin: 0 !important;
  opacity: 0.86 !important;
  filter: none !important;
}

/* Tooltip sits on the logo cell and scrolls with the belt. */
#building .stack-tip {
  position: absolute !important;
  inset: 0 !important;
  z-index: 3 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 4px !important;
  padding: 6px 4px !important;
  text-align: center !important;
  pointer-events: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
  transition:
    opacity 140ms linear,
    visibility 140ms linear !important;
  border: 1px solid rgba(20, 18, 15, 0.14) !important;
  background: color-mix(in srgb, var(--home-paper, #f6f6f4) 94%, transparent) !important;
  box-shadow: none !important;
}

#building .stack-wall__row > li:hover .stack-tip,
#building .stack-wall__row > li:focus-within .stack-tip,
#building .stack-wall__row > li.is-active .stack-tip {
  opacity: 1 !important;
  visibility: visible !important;
}

#building .stack-wall__row > li:hover img,
#building .stack-wall__row > li:focus-within img,
#building .stack-wall__row > li.is-active img {
  opacity: 0.12 !important;
}

#building .stack-tip__name {
  font: 500 11px / 1.15 "Archivo", ui-sans-serif, system-ui, sans-serif !important;
  letter-spacing: -0.02em !important;
  color: var(--home-ink, #14120f) !important;
}

#building .stack-tip__desc {
  font: 400 9px / 1.3 var(--mono, ui-monospace, monospace) !important;
  letter-spacing: 0 !important;
  color: var(--home-soft, #3c3a36) !important;
}

@keyframes building-marquee {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(-50%, 0, 0); }
}

@media (max-width: 720px) {
  #building .stack-carousel,
  #building .stack-track,
  #building .stack-marquee,
  #building .stack-wall {
    height: 240px !important;
    min-height: 0 !important;
  }

  #building .stack-carousel,
  #building .stack-track {
    min-height: 240px !important;
  }

  #building .stack-wall {
    --stack-cell: 72px;
    --stack-gap-x: 18px;
    gap: 6px !important;
    padding: 3px 0 !important;
  }

  #building .stack-wall__row > li {
    flex-basis: var(--stack-cell) !important;
    width: var(--stack-cell) !important;
    height: 76px !important;
    padding: 3px !important;
  }

  #building .stack-wall__row > li img,
  #building .stack-wall__row > li[data-ink="mono"] img {
    width: 52px !important;
    height: 52px !important;
    max-width: 52px !important;
    max-height: 52px !important;
  }
}
