.product-inventory-gallery,
.product-editor {
  background: #fff;
  border: 1px solid rgba(33, 37, 41, 0.08);
  border-radius: 8px;
  box-shadow: 0 12px 28px rgba(33, 37, 41, 0.05);
  min-height: 420px;
  padding: 2.25rem;
}

.product-inventory-gallery__header,
.product-editor__header {
  align-items: flex-start;
  display: flex;
  gap: 1.5rem;
  justify-content: space-between;
}

.product-inventory-gallery__eyebrow,
.product-editor__eyebrow {
  color: #b08a48;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  margin: 0;
  text-transform: uppercase;
}

.product-inventory-gallery__title,
.product-editor__title {
  color: #26231e;
  font-size: 2rem;
  margin: 0.5rem 0 1rem;
}

.product-inventory-gallery__lead,
.product-editor__lead {
  color: #3d3a35;
  margin: 0;
  max-width: 48rem;
}

.product-inventory-gallery__actions,
.product-editor__actions,
.product-inventory-back-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.product-inventory-gallery .btn-primary,
.product-editor .btn-primary {
  background: #b08a48;
  border-color: #b08a48;
  color: #fff;
}

.product-inventory-gallery .btn-primary:hover,
.product-inventory-gallery .btn-primary:focus,
.product-editor .btn-primary:hover,
.product-editor .btn-primary:focus {
  background: #8f6d35;
  border-color: #8f6d35;
}

.product-inventory-gallery .btn-outline-primary,
.product-editor .btn-outline-primary,
.product-inventory-back-row .btn-outline-primary {
  border-color: #b08a48;
  color: #5f4721;
}

.product-inventory-gallery .btn-outline-primary:hover,
.product-inventory-gallery .btn-outline-primary:focus,
.product-editor .btn-outline-primary:hover,
.product-editor .btn-outline-primary:focus,
.product-inventory-back-row .btn-outline-primary:hover,
.product-inventory-back-row .btn-outline-primary:focus {
  background: #b08a48;
  border-color: #b08a48;
  color: #fff;
}

.product-inventory-filters {
  background: #faf8f4;
  border: 1px solid #e8dfd1;
  border-radius: 8px;
  display: grid;
  gap: 0.85rem;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 2rem 0 1.25rem;
  padding: 1rem;
}

.product-inventory-filter {
  display: grid;
  gap: 0.35rem;
}

.product-inventory-filter__label,
.product-editor-field__label,
.product-editor-checkbox__label {
  color: #4a443b;
  font-size: 0.82rem;
  font-weight: 700;
}

.product-inventory-filter__control,
.product-editor-field__control {
  border-color: #d7c9b4;
}

.product-inventory-filter__control:focus,
.product-editor-field__control:focus {
  border-color: #b08a48;
  box-shadow: 0 0 0 0.2rem rgba(176, 138, 72, 0.16);
}

.product-inventory-gallery__count {
  color: #6b665d;
  font-size: 0.9rem;
  margin: 0 0 1rem;
}

.product-inventory-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.product-inventory-card {
  border: 1px solid #e3ddd3;
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(33, 37, 41, 0.05);
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
}

.product-inventory-card__media {
  aspect-ratio: 4 / 3;
  background: #f0ebe3;
  overflow: hidden;
}

.product-inventory-card__image {
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.product-inventory-card__placeholder {
  align-items: center;
  color: #9b8a70;
  display: flex;
  font-size: 2rem;
  height: 100%;
  justify-content: center;
}

.product-inventory-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 1.1rem;
}

.product-inventory-card__type {
  color: #8f6d35;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  margin: 0 0 0.35rem;
  text-transform: uppercase;
}

.product-inventory-card__title {
  color: #26231e;
  font-size: 1.2rem;
  margin: 0;
}

.product-inventory-card__sku {
  color: #777066;
  font-size: 0.85rem;
  margin: 0.25rem 0 0;
}

.product-inventory-card__price {
  color: #5f4721;
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0.9rem 0;
}

.product-inventory-card__meta {
  display: grid;
  gap: 0.55rem;
  margin: 0 0 1rem;
}

.product-inventory-card__meta-item {
  align-items: baseline;
  display: flex;
  gap: 0.75rem;
  justify-content: space-between;
}

.product-inventory-card__meta-label,
.product-inventory-card__meta-value {
  font-size: 0.8rem;
  margin: 0;
}

.product-inventory-card__meta-label {
  color: #777066;
}

.product-inventory-card__meta-value {
  color: #3d3a35;
  font-weight: 600;
  text-align: right;
}

.product-inventory-card__edit {
  margin-top: auto;
  width: 100%;
}

.product-inventory-state {
  background: #faf8f4;
  border: 1px dashed #d7c9b4;
  border-radius: 8px;
  color: #6b665d;
  margin: 2rem 0 0;
  padding: 2rem;
  text-align: center;
}

.product-inventory-state--error,
.product-editor__status--error {
  background: #fff4f2;
  border-color: #d8a39b;
  color: #8a3028;
}

.product-editor-section {
  border-top: 1px solid #e8dfd1;
  margin-top: 2rem;
  padding-top: 1.5rem;
}

.product-editor-section[hidden] {
  display: none;
}

.product-editor-section__title,
.product-editor-publication-note__title {
  color: #3d352c;
  font-size: 1.2rem;
  margin: 0 0 0.35rem;
}

.product-editor-section__lead,
.product-editor-publication-note__text {
  color: #6b665d;
  margin: 0 0 1rem;
}

.product-editor-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.product-editor-field {
  display: grid;
  gap: 0.35rem;
}

.product-editor-field--wide {
  grid-column: 1 / -1;
}

.product-editor-field__help {
  color: #777066;
  font-size: 0.78rem;
  margin: 0;
}

.product-editor-checkbox {
  align-items: flex-start;
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  padding-top: 0.4rem;
}

.product-editor-checkbox .product-editor-field__help {
  flex-basis: 100%;
  padding-left: 1.6rem;
}

.product-editor-checkbox .form-check-input:checked {
  background-color: #b08a48;
  border-color: #b08a48;
}

.product-editor-structured {
  background: #faf8f4;
  border: 1px solid #e8dfd1;
  border-radius: 8px;
  padding: 1rem;
}

.product-editor-structured__header {
  align-items: flex-start;
  display: flex;
  gap: 1rem;
  justify-content: space-between;
}

.product-editor-structured__title {
  color: #3d352c;
  font-size: 1rem;
  margin: 0 0 0.25rem;
}

.product-editor-structured__rows,
.product-editor-nested-list {
  display: grid;
  gap: 0.75rem;
  margin-top: 0.85rem;
}

.product-editor-structured__empty {
  color: #777066;
  margin: 0;
}

.product-editor-structured-row {
  background: #fff;
  border: 1px solid #ded5c8;
  border-radius: 8px;
  display: grid;
  gap: 0.85rem;
  padding: 1rem;
}

.product-editor-structured-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.product-editor-structured-grid--three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.product-editor-structured-grid--two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.product-editor-structured-control {
  display: grid;
  gap: 0.35rem;
  min-width: 0;
}

.product-editor-structured-control:has(.form-check-input) {
  align-content: start;
}

.product-editor-nested-list {
  border-top: 1px solid #e8dfd1;
  padding-top: 0.85rem;
}

.product-editor-nested-row {
  align-items: end;
  display: grid;
  gap: 0.65rem;
  grid-template-columns: minmax(0, 1fr) auto;
}

.product-editor-nested-row--selection {
  grid-template-columns: repeat(2, minmax(0, 1fr)) auto;
}

.product-editor-structured-remove {
  justify-self: end;
}

.product-editor-structured__standalone-action {
  margin-top: 0.85rem;
}

.product-editor-publication-note {
  background: #faf8f4;
  border: 1px solid #e8dfd1;
  border-radius: 8px;
  margin-top: 2rem;
  padding: 1rem;
}

.product-editor-publication-note__text {
  margin: 0;
}

.product-editor__status {
  border: 1px solid transparent;
  border-radius: 8px;
  margin: 1.25rem 0 0;
  min-height: 1.5rem;
  padding: 0.65rem;
}

.product-editor__status:empty {
  padding: 0;
}

.product-editor__status--success {
  background: #edf8f0;
  border-color: #a8d4b3;
  color: #27653a;
}

.product-editor__actions {
  justify-content: flex-end;
  margin-top: 1rem;
}

.product-inventory-back-row {
  margin-bottom: 1rem;
}

.product-import-chooser,
.product-import-panel {
  background: #fff;
  border: 1px solid #e8dfd1;
  border-radius: 12px;
  box-shadow: 0 10px 28px rgb(61 53 44 / 8%);
  padding: 2rem;
}

.product-import-chooser__choices {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  margin-top: 1.25rem;
}

.product-import-chooser__choice {
  background: #faf8f4;
  border: 1px solid #e8dfd1;
  border-radius: 10px;
  padding: 1.25rem;
}

.product-import-chooser__title {
  color: #3d352c;
  font-size: 1.05rem;
  margin: 0 0 0.5rem;
}

.product-import-top-actions,
.product-import-upload,
.product-import-save-row {
  margin-top: 1.25rem;
}

.product-import-status {
  border: 1px solid #e8dfd1;
  border-radius: 8px;
  color: #5f574d;
  margin: 1rem 0 0;
  padding: 0.75rem;
}

.product-import-status--success {
  background: #edf8f0;
  border-color: #a8d4b3;
  color: #27653a;
}

.product-import-status--warning {
  background: #fff8e8;
  border-color: #dec48f;
  color: #6b531f;
}

.product-import-status--error {
  background: #fff0f0;
  border-color: #d8a4a4;
  color: #7d2929;
}

.product-import-summary {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  margin-top: 1.25rem;
}

.product-import-summary__item {
  background: #faf8f4;
  border: 1px solid #e8dfd1;
  border-radius: 8px;
  display: grid;
  gap: 0.2rem;
  padding: 0.75rem;
}

.product-import-summary__label {
  color: #777066;
  font-size: 0.78rem;
}

.product-import-summary__value {
  color: #3d352c;
  overflow-wrap: anywhere;
}

.product-import-table-wrap {
  margin-top: 1.25rem;
}

.product-import-table {
  min-width: 960px;
}

.product-import-product-title {
  display: block;
  min-width: 180px;
}

.product-import-external-id {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.78rem;
  overflow-wrap: anywhere;
}

.product-import-match {
  font-weight: 600;
}

.product-import-match--new,
.product-import-match--matching {
  color: #27653a;
}

.product-import-match--conflicting,
.product-import-match--error {
  color: #7d2929;
}

.product-import-issues {
  font-size: 0.8rem;
  margin-top: 0.45rem;
}

.product-import-issues--warning {
  color: #6b531f;
}

.product-import-issues--error {
  color: #7d2929;
}

.product-import-issues ul {
  margin: 0.4rem 0 0;
  padding-left: 1.2rem;
}

.product-import-decision {
  min-width: 190px;
}

@media (max-width: 991.98px) {
  .product-inventory-filters,
  .product-inventory-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767.98px) {
  .product-inventory-gallery,
  .product-editor {
    padding: 1.25rem;
  }

  .product-inventory-gallery__header,
  .product-editor__header {
    display: grid;
  }

  .product-inventory-gallery__actions,
  .product-editor__actions {
    width: 100%;
  }

  .product-inventory-gallery__actions .btn,
  .product-editor__actions .btn {
    flex: 1 1 auto;
  }

  .product-inventory-filters,
  .product-inventory-grid,
  .product-editor-grid,
  .product-editor-structured-grid,
  .product-editor-structured-grid--three,
  .product-editor-structured-grid--two,
  .product-editor-nested-row,
  .product-editor-nested-row--selection {
    grid-template-columns: 1fr;
  }

  .product-editor-structured__header {
    display: grid;
  }

  .product-editor-structured-remove {
    justify-self: stretch;
  }

  .product-editor-field--wide {
    grid-column: auto;
  }
}
