.erpel-config-panel.erpel-detail-panel {
  flex: 1 1 auto;
  min-width: 0;
}

.erpel-config-panel .table-container {
  overflow-x: auto;
  max-width: 100%;
}

/* Transparent body cells only — thead uses --erpel-table-head-bg (sticky/scroll). */
.erpel-config-table tbody td {
  background-color: transparent;
}

/* P14.7 — Configuration overview & table actions (Stammdaten-Parität) */
.erpel-config-index {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(16rem, 100%), 1fr));
  gap: 1rem;
}

.erpel-config-index-tile {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  padding: 1.25rem 1.15rem;
  border: 1px solid var(--erpel-border-subtle);
  border-radius: var(--erpel-radius);
  background: var(--erpel-surface-subtle);
  color: inherit;
  text-decoration: none;
  transition:
    border-color 0.12s ease,
    background-color 0.12s ease,
    color 0.12s ease;
}

.erpel-config-index-tile:hover,
.erpel-config-index-tile:focus-visible {
  border-color: var(--erpel-brand);
  background: color-mix(in srgb, var(--erpel-brand) 8%, var(--erpel-white));
  color: inherit;
  outline: none;
}

.erpel-config-index-tile:hover .erpel-config-tile-title,
.erpel-config-index-tile:hover .erpel-config-tile-icon {
  color: var(--erpel-brand);
}

.erpel-config-tile-icon {
  color: var(--erpel-text);
  transition: color 0.12s ease;
}

.erpel-config-tile-title {
  transition: color 0.12s ease;
}

.erpel-config-card-grid > .column {
  display: flex;
  min-width: 0;
}

.erpel-config-status-card {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-height: 8.5rem;
}

.erpel-config-brand-name {
  min-height: 0;
  line-height: 1.25rem;
}

.erpel-config-card-head {
  min-width: 0;
}

.erpel-config-brand {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
  flex: 1 1 auto;
}

.erpel-config-brand-logo-slot {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  flex: 0 0 2.25rem;
}

/* Hersteller mit eigenem Shop: kleiner Warenkorb unten rechts am Logo */
.erpel-config-brand-shop {
  position: absolute;
  right: -0.4rem;
  bottom: -0.35rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.05rem;
  height: 1.05rem;
  border: 1px solid var(--erpel-border);
  border-radius: 50%;
  background: var(--erpel-surface);
  color: var(--erpel-text);
  font-size: 0.7rem;
  line-height: 1;
}

.erpel-config-brand-logo {
  display: block;
  width: auto;
  height: auto;
  max-width: 2.25rem;
  max-height: 2.25rem;
  object-fit: contain;
  object-position: center;
}

.erpel-config-card-status {
  margin-top: auto;
  min-height: 2.6rem;
}

.erpel-config-page-title {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.erpel-config-page-title .erpel-config-brand-logo {
  max-height: 2.5rem;
  max-width: 2.5rem;
}

.erpel-config-status-card.erpel-box,
.erpel-config-status-card {
  border: 1px solid var(--erpel-border-subtle);
  border-radius: var(--erpel-radius);
  background: var(--erpel-surface-subtle);
  padding: 1.25rem;
}

.erpel-config-status-card.erpel-config-status-card--incident {
  border-color: var(--erpel-danger, #cc0f35);
}

/* Provider-Karten (Sourcing, Paketdienste): ganze Kachel klickbar über einen Stretched Link
   auf dem Namen; Hover wie .erpel-config-index-tile. Der Forge-Link im Status liegt darüber. */
.erpel-config-status-card--link {
  position: relative;
  transition:
    border-color 0.12s ease,
    background-color 0.12s ease;
}

.erpel-config-card-link {
  color: inherit;
  transition: color 0.12s ease;
}

.erpel-config-card-link::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.erpel-config-card-link:focus-visible {
  outline: none;
}

.erpel-config-status-card--link:hover,
.erpel-config-status-card--link:has(.erpel-config-card-link:focus-visible) {
  border-color: var(--erpel-brand);
  background: color-mix(in srgb, var(--erpel-brand) 8%, var(--erpel-white));
}

.erpel-config-status-card--link:hover .erpel-config-card-link,
.erpel-config-card-link:focus-visible {
  color: var(--erpel-brand);
}

.erpel-config-status-card--link .erpel-config-card-status a {
  position: relative;
  z-index: 1;
}

.erpel-config-actions-th,
.erpel-config-actions-cell {
  width: 5.25rem;
  min-width: 5.25rem;
  max-width: 5.25rem;
  padding-left: 0.25rem;
  padding-right: 0.35rem;
  overflow: visible;
  text-overflow: clip;
  white-space: nowrap;
  text-align: right;
}

.erpel-config-actions-th--single,
.erpel-config-actions-cell--single {
  width: 2.85rem;
  min-width: 2.85rem;
  max-width: 2.85rem;
}

.erpel-config-actions-th--triple,
.erpel-config-actions-cell--triple {
  width: 7.75rem;
  min-width: 7.75rem;
  max-width: 7.75rem;
}


.erpel-template-picker .erpel-template-chip {
  cursor: pointer;
  max-width: 100%;
  white-space: normal;
  text-align: left;
}

.erpel-template-picker .erpel-template-chip:hover {
  background-color: var(--erpel-info-tint);
}

.erpel-template-picker .erpel-template-chip.is-hidden,
.erpel-template-picker .erpel-template-picker-category.is-hidden {
  display: none !important;
}

.erpel-config-disclosure {
  /* Chevron column + summary gap: the body is indented by exactly this, so its left edge
     lines up with the title text. The right edge stays flush with the page content. */
  --erpel-disclosure-marker: 0.75rem;
  --erpel-disclosure-gap: 0.75rem;
  border-top: 1px solid var(--erpel-border);
  margin: 0.5rem 0 1.25rem;
  padding-top: 0.75rem;
}

.erpel-config-disclosure > summary {
  align-items: center;
  cursor: pointer;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem var(--erpel-disclosure-gap);
  list-style: none;
}

.erpel-config-disclosure > summary::before {
  content: "▸";
  flex: 0 0 var(--erpel-disclosure-marker);
  font-size: 0.75rem;
  line-height: 1;
  text-align: center;
}

.erpel-config-disclosure[open] > summary::before {
  content: "▾";
}

.erpel-config-disclosure > summary::-webkit-details-marker {
  display: none;
}

.erpel-config-disclosure > summary .title {
  margin-bottom: 0;
}

.erpel-config-disclosure > summary .button,
.erpel-config-disclosure > summary .tag,
.erpel-config-disclosure > summary .title {
  flex: 0 1 auto;
}

.erpel-config-disclosure__body {
  padding-left: calc(var(--erpel-disclosure-marker) + var(--erpel-disclosure-gap));
  padding-top: 0.75rem;
}

.erpel-config-section-rule {
  border-top: 1px solid var(--erpel-black-a8);
}

.erpel-config-disclosure-summary {
  cursor: pointer;
}

.erpel-sourcing-cache-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.erpel-sourcing-cache-actions > form {
  align-items: center;
  display: flex;
  flex: 0 0 auto;
  margin: 0;
}

.erpel-sourcing-cache-clear-form {
  flex-wrap: nowrap;
  gap: 0.75rem;
}

/* Fixed box so the combobox (default width:100%) cannot run into the button. */
.erpel-sourcing-cache-provider {
  flex: 0 0 12rem;
  width: 12rem;
  max-width: 100%;
}

.erpel-sourcing-cache-provider .select,
.erpel-sourcing-cache-provider .erpel-searchable-select.is-enhanced,
.erpel-sourcing-cache-provider .erpel-searchable-select.is-enhanced .erpel-searchable-select__input {
  box-sizing: border-box;
  max-width: 100%;
  width: 100%;
}

.erpel-sourcing-ttl {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(9rem, 100%), 1fr));
  gap: 0.5rem 1rem;
  margin: 0;
}

.erpel-sourcing-ttl dd {
  margin: 0;
  font-weight: 600;
}

.erpel-sourcing-cache-flash:not(:empty) {
  margin-bottom: 0.75rem;
}

.erpel-sourcing-pattern-example {
  word-break: break-all;
}

.erpel-col-usage {
  min-width: 8rem;
}
