.bh-tool-shell {
  position: sticky;
  top: 0;
  z-index: 2147483000;
  display: grid;
  grid-template-columns: minmax(190px, 0.8fr) minmax(180px, 0.7fr) minmax(360px, 1.2fr);
  align-items: center;
  gap: 14px;
  min-height: 58px;
  padding: 9px 16px;
  border-bottom: 1px solid rgba(30, 35, 40, 0.14);
  background: rgba(247, 244, 236, 0.97);
  color: #1e2328;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
  box-shadow: 0 8px 24px rgba(30, 35, 40, 0.08);
  backdrop-filter: blur(12px);
}

.bh-tool-shell,
.bh-tool-shell * {
  box-sizing: border-box;
}

.bh-tool-brand,
.bh-tool-nav,
.bh-tool-current,
.bh-tool-actions,
.bh-tool-switcher {
  display: inline-flex;
  align-items: center;
}

.bh-tool-brand {
  gap: 10px;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.bh-tool-brand-mark {
  display: inline-grid;
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 8px;
  background: #1e2328;
  color: #fff;
  font-size: 0.82rem;
  font-weight: 900;
}

.bh-tool-brand-text {
  display: grid;
  gap: 1px;
  min-width: 0;
  line-height: 1.1;
}

.bh-tool-brand-text strong {
  color: #1e2328;
  font-size: 0.95rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bh-tool-brand-text span {
  color: #63707a;
  font-size: 0.72rem;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bh-tool-current {
  display: grid;
  justify-content: center;
  min-width: 0;
  text-align: center;
  line-height: 1.1;
}

.bh-tool-current-kicker {
  color: #1f766f;
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.bh-tool-current strong {
  color: #1e2328;
  font-size: 0.95rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bh-tool-actions {
  justify-content: flex-end;
  gap: 8px;
  min-width: 0;
}

.bh-tool-switcher {
  gap: 7px;
  min-width: min(300px, 42vw);
}

.bh-tool-switcher span {
  color: #63707a;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.bh-tool-switcher select {
  width: 100%;
  min-height: 34px;
  padding: 0 30px 0 10px;
  border: 1px solid #d8ddd8;
  border-radius: 8px;
  background: #fffefa;
  color: #1e2328;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 800;
}

.bh-tool-nav {
  justify-content: flex-end;
  gap: 4px;
  min-width: 0;
}

.bh-tool-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 10px;
  border-radius: 8px;
  color: #63707a;
  font-size: 0.82rem;
  font-weight: 850;
  text-decoration: none;
  white-space: nowrap;
}

.bh-tool-nav a:hover,
.bh-tool-nav a:focus-visible,
.bh-tool-switcher select:focus-visible {
  background: #fffefa;
  color: #1e2328;
  outline: 1px solid rgba(31, 118, 111, 0.3);
}

.bh-missing-tool {
  width: min(720px, calc(100% - 32px));
  margin: 60px auto;
  padding: 24px;
  border: 1px solid #d8ddd8;
  border-radius: 8px;
  background: #fffefa;
  color: #1e2328;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.bh-tool-practice-strip {
  position: relative;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 10px 16px;
  border-bottom: 1px solid rgba(30, 35, 40, 0.1);
  background: #fffefa;
  color: #1e2328;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.bh-tool-practice-strip div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.bh-tool-practice-strip span {
  color: #1f766f;
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.bh-tool-practice-strip strong {
  color: #1e2328;
  font-size: 0.9rem;
  line-height: 1.25;
}

.bh-tool-practice-strip a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 11px;
  border: 1px solid #d8ddd8;
  border-radius: 8px;
  background: #f0ede4;
  color: #1e2328;
  font-size: 0.82rem;
  font-weight: 850;
  text-decoration: none;
  white-space: nowrap;
}

.bh-tool-practice-strip a:hover,
.bh-tool-practice-strip a:focus-visible {
  border-color: rgba(31, 118, 111, 0.42);
  background: #e4f0eb;
  outline: 0;
}

@media (max-width: 980px) {
  .bh-tool-shell {
    grid-template-columns: minmax(170px, 1fr) minmax(160px, 1fr);
  }

  .bh-tool-actions {
    grid-column: 1 / -1;
    justify-content: stretch;
  }

  .bh-tool-switcher {
    flex: 1 1 auto;
    min-width: 0;
  }
}

@media (max-width: 640px) {
  .bh-tool-shell {
    grid-template-columns: 1fr;
    align-items: stretch;
    gap: 8px;
    padding: 9px 10px;
  }

  .bh-tool-current {
    justify-content: flex-start;
    text-align: left;
  }

  .bh-tool-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .bh-tool-switcher {
    width: 100%;
  }

  .bh-tool-nav {
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .bh-tool-practice-strip {
    grid-template-columns: 1fr;
    align-items: stretch;
    padding: 10px;
  }

  .bh-tool-practice-strip a {
    justify-content: center;
    white-space: normal;
  }
}
