/* The module grid: the Hub's home (SDOT handoff 034). Dark first (033); every colour is a token, so light follows. */
@view-transition { navigation: auto }
::view-transition-group(mod) { animation-duration: .4s; animation-timing-function: cubic-bezier(.16, 1, .3, 1); overflow: clip; border-radius: 16px }
::view-transition-old(mod), ::view-transition-new(mod) { height: 100%; width: 100%; object-fit: cover }
@media (prefers-reduced-motion: reduce) {
  ::view-transition-old(root), ::view-transition-new(root) { animation-duration: 0s }
}

/* the zoom (fallback, and for modules on another host): a clone grows to fill the screen, then the page changes */
.gh-zoomer { position: fixed; z-index: 90; background: var(--bh-surface-2); border: 1px solid var(--bh-accent); border-radius: 16px; pointer-events: none }

/* top bar: the grid button and the mini-map */
.bh-minimap { display: grid !important; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 8px; min-width: 264px }
.bh-minimap[hidden] { display: none !important }
.bh-minimap a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 64px; padding: 6px 4px; border-radius: 10px;
  color: var(--bh-ink); text-decoration: none; font: 500 12px/1.2 Inter, system-ui, sans-serif; text-align: center }
.bh-minimap a:hover, .bh-minimap a:focus-visible { background: var(--bh-surface-2) }
.bh-minimap a[aria-current="true"] { background: color-mix(in srgb, var(--bh-accent) 16%, transparent) }
.bh-topbar__grid { display: inline-flex }

@media (max-width: 767px) { .bh-topbar__map { display: none } }

/* A page shown inside a Hub pane (041; static/js/bh-embed.js sets the class): the pane's title bar replaces the shell */
.bh-embedded .bh-rail, .bh-embedded .bh-topbar, .bh-embedded .bh-app__tabbar, .bh-embedded .bh-env, .bh-embedded .bh-skip { display: none !important }
.bh-embedded .bh-app { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto; padding: 0 }
.bh-embedded .bh-main { grid-column: 1; grid-row: 1; padding: 16px }
