.component-inspector {
  z-index: 4;
  background: var(--panel);
}
.component-inspector-header {
  height: 42px;
  background: #f7f9fa;
  border-bottom: 1px solid var(--border);
}
.component-inspector-body > [hidden] { display: none !important; }
.component-inspector-title {
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.component-inspector-title code {
  color: var(--muted);
}
.component-inspector-context {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 7px 8px;
  color: #35526d;
  background: #edf6ff;
  border: 1px solid #c9def2;
  border-radius: 4px;
  font-size: 11px;
  line-height: 1.35;
}
.component-inspector-context[hidden] { display: none; }
.descendant-rule-panel { grid-column: 1 / -1; min-width: 0; }
.descendant-rule-card {
  min-width: 0;
  padding: 8px;
  background: #fff;
  border: 1px solid #cbd6de;
  border-radius: 4px;
}
.descendant-rule-card.is-active { border-color: #70acd4; box-shadow: inset 3px 0 var(--accent); }
.descendant-rule-card .component-options-action.is-primary:disabled { opacity: 1; }
.descendant-rule-state-row {
  min-width: 0;
  padding: 5px 6px;
  color: #263340;
  background: #f3f7fa;
  border-radius: 3px;
}
.descendant-rule-card-details { padding-top: 7px; border-top: 1px solid #dce5eb; }
.descendant-rule-utility-summary {
  min-width: 0;
  padding: 7px;
  color: #35526d;
  background: #f5f9fc;
  border: 1px solid #d5e2eb;
  border-radius: 4px;
}
.descendant-rule-utility-summary > section { display: grid; gap: 4px; min-width: 0; }
.descendant-rule-utility-change {
  display: grid;
  grid-template-columns: minmax(90px, auto) minmax(0, 1fr);
  gap: 6px;
  align-items: start;
  font-size: 10px;
}
.descendant-rule-utility-change > span { font-weight: 700; }
.descendant-rule-utility-change code {
  min-width: 0;
  color: #263340;
  font-size: 10px;
  overflow-wrap: anywhere;
  white-space: normal;
}
.descendant-rule-condition-row { min-width: 0; }
.descendant-rule-variant-list { grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); }
.descendant-rule-variant-option {
  min-width: 0;
  padding: 4px 6px;
  color: #263340;
  background: #fff;
  border: 1px solid #d6e0e7;
  border-radius: 3px;
  font-size: 11px;
  cursor: pointer;
}
.descendant-rule-variant-option input { margin: 0; }
.descendant-rule-variant-option:has(input:checked) {
  color: #075f9f;
  background: #e5f2fb;
  border-color: var(--accent);
  box-shadow: inset 3px 0 var(--accent);
  font-weight: 700;
}
.descendant-rule-panel select,
.descendant-rule-panel input[type="number"] { width: 100%; min-width: 0; }
.descendant-state-picker-dialog {
  align-self: center;
  width: min(440px, 100%);
  max-height: calc(100vh - 40px);
  overflow: auto;
}
.descendant-state-picker-dialog h2 { margin: 0; }
.descendant-state-picker-dialog > p { margin: 8px 0 12px; }
.descendant-state-picker-options { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.descendant-state-picker-options .component-options-action { text-align: left; }
.nested-component-edit-exit {
  padding: 4px 7px;
  color: #245a87;
  background: #fff;
  border: 1px solid #a8c9e6;
  border-radius: 3px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.nested-component-edit-exit:hover { background: #f7fbff; }
.nested-component-patch-summary {
  padding: 9px;
  color: #35526d;
  background: #edf6ff;
  border: 1px solid #c9def2;
  border-radius: 4px;
  font-size: 11px;
  line-height: 1.4;
}
.nested-component-patch-summary code {
  display: block;
  margin-top: 6px;
  padding: 6px;
  overflow-wrap: anywhere;
  color: #263340;
  background: rgba(255, 255, 255, 0.75);
  border-radius: 3px;
  white-space: normal;
}
.component-inspector-target {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}
.component-inspector-target[hidden] { display: none; }
.component-inspector-target select {
  min-width: 0;
  height: 28px;
  padding: 0 24px 0 7px;
  color: #263340;
  background-color: #fff;
  border: 1px solid var(--border);
  border-radius: 3px;
  cursor: pointer;
}
.utility-bundle-targets {
  display: grid;
  gap: 6px;
  padding: 8px;
  background: #f5f9fc;
  border: 1px solid #cddce7;
  border-radius: 4px;
}
.utility-bundle-targets[hidden] { display: none; }
.utility-bundle-target-hint {
  margin: 0;
  color: #52606d;
  font-size: 11px;
  line-height: 1.4;
}
.utility-bundle-target-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(135px, 1fr));
  gap: 5px;
}
.utility-bundle-target {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
  min-width: 0;
  padding: 6px 7px;
  color: #263340;
  background: #fff;
  border: 1px solid #cbd6de;
  border-radius: 3px;
  text-align: left;
  cursor: pointer;
}
.utility-bundle-target:hover { border-color: #74a9cc; background: #f3faff; }
.utility-bundle-target:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.utility-bundle-target.is-active {
  border-color: var(--accent);
  box-shadow: inset 3px 0 var(--accent);
}
.utility-bundle-target-copy {
  display: grid;
  gap: 1px;
  min-width: 0;
}
.utility-bundle-target-copy strong,
.utility-bundle-target-copy code {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.utility-bundle-target-copy strong { font-size: 11px; }
.utility-bundle-target-copy code { color: #71808d; font-size: 9px; }
.utility-bundle-target-count {
  padding: 2px 5px;
  color: #52606d;
  background: #e9edf0;
  border-radius: 9px;
  font-size: 9px;
  white-space: nowrap;
}
.utility-bundle-target.is-active .utility-bundle-target-count {
  color: #075f9f;
  background: #e5f2fb;
}
.component-inspector-tabs {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-self: stretch;
}
.component-inspector-tabs.has-definition { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.component-inspector-tab {
  height: 41px;
  padding: 0 8px;
  color: var(--muted);
  background: #f7f9fa;
  border: 0;
  border-bottom: 2px solid transparent;
}
.component-inspector-tab.active {
  color: var(--accent);
  background: #fff;
  border-bottom-color: var(--accent);
}
.component-props {
  align-content: start;
}
.component-props[hidden] { display: none !important; }
