/* Behavior panel injected into the shape viewer.
   Sits below the existing fingerprint/nav row, full-width. */

.behavior-panel {
  margin: 1rem 0 0;
  background: linear-gradient(135deg, #1a0a1a, #0a0a0a);
  border: 1px solid #b5f55;
  border-radius: 6px;
  padding: 0.85rem 1.05rem;
  font-family: ui-monospace, monospace;
  font-size: 0.85rem;
  color: #d8d8d8;
}
.bp-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 0.55rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid #2a1a2a;
}
.bp-title {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: #b5f;
}
.bp-step {
  font-size: 0.74rem;
  color: #888;
}

.bp-rows {
  display: grid;
  gap: 0.5rem;
}
.bp-row {
  display: grid;
  grid-template-columns: 130px 1fr;
  align-items: center;
  gap: 0.7rem;
}
.bp-row-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #888;
}
.bp-row-value {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  background: #111;
  border: 1px solid #2a2a2a;
  border-radius: 3px;
  padding: 0.4rem 0.7rem;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s, background 0.15s;
}
.bp-row-value:hover {
  border-color: #f5d76e;
  background: #181818;
}
.bp-row-value:hover .bp-row-arrow {
  color: #f5d76e;
}
.bp-row-arrow {
  color: #555;
  font-size: 1rem;
  flex-shrink: 0;
}

.bp-mix-row .bp-mix-bar {
  display: flex;
  height: 16px;
  border-radius: 3px;
  background: #1a1a1a;
  overflow: hidden;
  border: 1px solid #2a2a2a;
}
.bp-mix-bar > i {
  display: block;
  height: 100%;
  position: relative;
}
.bp-mix-bar > i:hover::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: #000;
  color: #fff;
  font-size: 0.7rem;
  padding: 0.2rem 0.45rem;
  border-radius: 3px;
  white-space: nowrap;
  z-index: 10;
}

.bp-disabled {
  opacity: 0.6;
}

/* Purity tier inline pills (reuse colors from category page) */
.bp-tier {
  display: inline-block;
  padding: 0.05rem 0.4rem;
  border-radius: 9px;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-left: 0.4rem;
  vertical-align: middle;
}
.bp-tier.tier-P1 { background:#1f4823; color:#6f9; }
.bp-tier.tier-P2 { background:#3a2f0a; color:#fbbf24; }
.bp-tier.tier-P3 { background:#3a2f00; color:#f5d76e; }
.bp-tier.tier-P4 { background:#3a1f00; color:#f97316; }
.bp-tier.tier-P5 { background:#3a0a0a; color:#ef4444; }

/* All-expressions strip + other behaviors */
.bp-section-title {
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #b5f;
  margin: 1rem 0 0.55rem;
  padding-top: 0.7rem;
  border-top: 1px solid #2a1a2a;
  display: flex;
  align-items: baseline;
  gap: 0.7rem;
  flex-wrap: wrap;
}
.bp-section-help {
  font-size: 0.7rem;
  font-weight: 400;
  color: #777;
  text-transform: none;
  letter-spacing: normal;
}
.bp-expression-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(56px, 1fr));
  gap: 0.3rem;
}
.bp-expr-cell {
  background: #111;
  border: 1px solid #2a2a2a;
  border-radius: 3px;
  padding: 0.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.18rem;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.12s, background 0.12s;
}
.bp-expr-cell:hover {
  border-color: #f5d76e;
  background: #181818;
}
.bp-expr-cell.is-current {
  border-color: #b5f;
  background: #1a0a1a;
  box-shadow: 0 0 0 2px #b5f33;
}
.bp-expr-cell img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
  background: #0a0a0a;
  border-radius: 2px;
}
.bp-expr-meta {
  font-family: ui-monospace, monospace;
  font-size: 0.6rem;
  color: #888;
  line-height: 1.2;
  text-align: center;
}
.bp-expr-dim {
  font-weight: 700;
  color: #6b8bff;
}
.bp-expr-dim.dim-4d { color: #b5f; }
.bp-expr-dec {
  color: #f5d76e;
}

/* Other behaviors columns */
.bp-other-behaviors {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
@media (max-width: 700px) {
  .bp-other-behaviors { grid-template-columns: 1fr; }
}
.bp-other-list {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.bp-other-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  background: #111;
  border: 1px solid #2a2a2a;
  border-radius: 3px;
  padding: 0.4rem 0.65rem;
  text-decoration: none;
  color: inherit;
  font-size: 0.78rem;
  transition: border-color 0.12s;
}
.bp-other-item:hover { border-color: #f5d76e; }
.bp-other-sig {
  flex: 1;
  font-family: ui-monospace, monospace;
  font-size: 0.78rem;
  line-height: 1.3;
}
.bp-other-count {
  flex-shrink: 0;
  font-family: ui-monospace, monospace;
  font-size: 0.7rem;
  color: #888;
}
.bp-other-arrow {
  color: #555;
  flex-shrink: 0;
}
.bp-other-item:hover .bp-other-arrow { color: #f5d76e; }
.bp-other-item.bp-disabled {
  opacity: 0.55;
  cursor: default;
  pointer-events: none;
}

/* hidden attribute beats class display rules above */
.behavior-panel[hidden] { display: none !important; }
