/* Splash — floating keyword field. Loaded on the front page only. */
.k-front body, body.k-front { margin: 0; background: #0b0b0b; }
body.k-front .wp-site-blocks { min-height: 100vh; }

#k-field {
  position: fixed; inset: clamp(150px, 20vh, 220px) 0 56px 0; overflow: hidden; z-index: 1;
  perspective: 1100px; perspective-origin: 50% 50%;
  cursor: default; user-select: none; -webkit-user-select: none;
}
.k-word {
  position: absolute; left: 0; top: 0; margin: 0;
  white-space: nowrap; line-height: 1; padding: .12em .2em;
  will-change: transform, opacity;
  transform-style: preserve-3d; backface-visibility: visible;
  cursor: pointer; text-decoration: none;
}
.k-word:hover { text-decoration: none; }
.k-word:focus-visible { outline: 2px solid #F0F0EC; outline-offset: 4px; }
.k-word .k-tip {
  position: absolute; left: 50%; top: 100%; transform: translateX(-50%);
  margin-top: .35em; padding: .3em .6em; border-radius: 2px;
  font: 500 11px/1.3 "Avenir Next", "Avenir", "Nunito Sans", system-ui, sans-serif; letter-spacing: .12em; text-transform: uppercase;
  color: #0b0b0b; background: #F0F0EC; white-space: nowrap;
  opacity: 0; pointer-events: none; transition: opacity .15s;
}
.k-word:hover .k-tip, .k-word:focus-visible .k-tip { opacity: 1; }

#k-hint {
  position: fixed; left: 0; right: 0; bottom: 62px; z-index: 3; text-align: center; pointer-events: none;
  font: 400 12px/1.4 "Avenir Next", "Avenir", "Nunito Sans", system-ui, sans-serif; letter-spacing: .14em; text-transform: uppercase;
  color: #F0F0EC; opacity: .45;
}

/* Related-works mini view (opens when a word maps to several projects) */
#k-related {
  position: fixed; inset: 0; z-index: 60; display: none;
  background: rgba(11,11,11,.92); color: #F0F0EC;
  padding: clamp(24px, 6vw, 80px);
  font-family: "Avenir Next", "Avenir", "Nunito Sans", system-ui, sans-serif;
}
#k-related.is-open { display: flex; flex-direction: column; justify-content: center; }
#k-related .k-eyebrow { margin: 0 0 1.2rem; }
#k-related h2 { margin: 0 0 1.5rem; font-weight: 500; font-size: clamp(1.6rem, 4vw, 3rem); letter-spacing: -.01em; }
#k-related ul { list-style: none; margin: 0; padding: 0; }
#k-related li { margin: 0; }
#k-related li a {
  display: block; padding: .8em 0; border-top: 1px solid rgba(240,240,236,.2);
  font-size: clamp(1.1rem, 2.4vw, 1.7rem); text-decoration: none;
}
#k-related li:last-child a { border-bottom: 1px solid rgba(240,240,236,.2); }
#k-related li a:hover { padding-left: .5em; }
#k-related button {
  position: absolute; top: 20px; right: clamp(16px, 4vw, 48px);
  background: none; border: 1px solid rgba(240,240,236,.4); color: #F0F0EC;
  font: 500 12px/1 "Avenir Next", "Avenir", "Nunito Sans", system-ui, sans-serif; letter-spacing: .14em; text-transform: uppercase;
  padding: .7em 1.1em; cursor: pointer;
}
#k-related button:hover { background: #F0F0EC; color: #0b0b0b; }

@media (prefers-reduced-motion: reduce) {
  .k-word { transition: none !important; }
}
