/* Shop admin workspace: stable sidebar, corrected permission columns and compact actions. */
.dsp-shops-shell {
  display: grid !important;
  grid-template-columns: 188px minmax(0, 1fr) !important;
  column-gap: 16px !important;
  align-items: start !important;
  width: calc(100% - 24px) !important;
  max-width: 1540px !important;
}

.dsp-shops-shell > * {
  grid-column: 2 !important;
  min-width: 0 !important;
}

.dsp-shops-shell > .dsp-shop-sidebar {
  grid-column: 1 !important;
  grid-row: 1 / span 80 !important;
  position: sticky !important;
  top: 14px !important;
  float: none !important;
  width: 188px !important;
  margin: 0 !important;
  padding: 10px !important;
  border: 1px solid #d9e6e0 !important;
  border-radius: 8px !important;
  background: #fff !important;
  box-shadow: 0 8px 24px rgba(18, 71, 53, .06) !important;
  z-index: 35 !important;
}

.dsp-shop-sidebar-brand {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  margin: 0 0 9px !important;
  padding: 2px 3px 10px !important;
  border-bottom: 1px solid #e4ece8 !important;
}

.dsp-shop-sidebar-brand .dsp-brand-mark {
  flex: 0 0 30px !important;
  width: 30px !important;
  height: 30px !important;
}

.dsp-shop-sidebar-brand > span:last-child,
.dsp-shop-sidebar-brand strong,
.dsp-shop-sidebar-brand small {
  display: block !important;
  min-width: 0 !important;
}

.dsp-shop-sidebar-brand strong {
  color: #173f31 !important;
  font-size: 11px !important;
  font-weight: 650 !important;
}

.dsp-shop-sidebar-brand small {
  margin-top: 1px !important;
  color: #84938d !important;
  font-size: 7.5px !important;
}

.dsp-shop-sidebar nav {
  display: grid !important;
  gap: 2px !important;
}

.dsp-shop-sidebar-label {
  margin: 7px 6px 3px !important;
  color: #91a099 !important;
  font-size: 7px !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
}

.dsp-shop-sidebar nav > a,
.dsp-shop-sidebar nav > button {
  appearance: none !important;
  display: grid !important;
  grid-template-columns: 22px minmax(0, 1fr) auto !important;
  align-items: center !important;
  gap: 7px !important;
  width: 100% !important;
  min-height: 34px !important;
  margin: 0 !important;
  padding: 6px 7px !important;
  border: 0 !important;
  border-radius: 6px !important;
  background: transparent !important;
  color: #536a61 !important;
  font-family: Prompt, sans-serif !important;
  text-align: left !important;
  text-decoration: none !important;
  cursor: pointer !important;
  box-shadow: none !important;
}

.dsp-shop-sidebar nav > a > span,
.dsp-shop-sidebar nav > button > span {
  display: grid !important;
  place-items: center !important;
  width: 22px !important;
  height: 22px !important;
  border-radius: 5px !important;
  background: #f0f5f2 !important;
  color: #557269 !important;
  font-size: 13px !important;
  line-height: 1 !important;
}

.dsp-shop-sidebar nav b {
  overflow: hidden !important;
  font-size: 9px !important;
  font-weight: 500 !important;
  line-height: 1.25 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.dsp-shop-sidebar nav em {
  display: inline-grid !important;
  place-items: center !important;
  min-width: 18px !important;
  height: 18px !important;
  padding: 0 4px !important;
  border-radius: 999px !important;
  background: #e9f7ef !important;
  color: #087954 !important;
  font-size: 7px !important;
  font-style: normal !important;
  font-weight: 650 !important;
}

.dsp-shop-sidebar nav > a:hover,
.dsp-shop-sidebar nav > button:hover,
.dsp-shop-sidebar nav > a.is-active {
  background: #eaf7f0 !important;
  color: #08704f !important;
}

.dsp-shop-sidebar nav > a.is-active > span {
  background: #087a57 !important;
  color: #fff !important;
}

.dsp-shops-heading {
  align-items: center !important;
  margin-bottom: 8px !important;
  padding-bottom: 10px !important;
  border-bottom: 1px solid #e1ebe6 !important;
}

.dsp-shops-heading h1 {
  font-size: 22px !important;
  line-height: 1.2 !important;
}

.dsp-shops-heading p {
  margin-top: 3px !important;
  font-size: 9px !important;
}

.dsp-shops-heading-actions > .dsp-consignment-workspace-button,
.dsp-shops-heading-actions > .dsp-sellout-manager-button,
.dsp-shops-heading-actions > .dsp-flex-auto-settings-button,
.dsp-shops-heading-actions > .dsp-approval-bell,
.dsp-shops-heading-actions > .dsp-birthday-bell {
  display: none !important;
}

.dsp-front-import-workspace,
.dsp-front-stock-workspace,
.dsp-device-imei-workspace {
  scroll-margin-top: 16px !important;
}

.dsp-shops-period-form {
  margin-top: 7px !important;
}

.dsp-shop-scope-tabs {
  margin-top: 8px !important;
}

.dsp-shops-table-wrap {
  overflow: visible !important;
  border-radius: 8px !important;
}

.dsp-shops-table {
  width: 100% !important;
  min-width: 0 !important;
  table-layout: fixed !important;
}

.dsp-shops-table th,
.dsp-shops-table td {
  padding: 9px 6px !important;
  overflow-wrap: normal !important;
  word-break: normal !important;
}

.dsp-shops-table th {
  color: #587068 !important;
  font-size: 7.5px !important;
  font-weight: 600 !important;
  line-height: 1.25 !important;
}

.dsp-shops-table tbody tr {
  height: auto !important;
  min-height: 0 !important;
}

.dsp-shops-table th:nth-child(3),
.dsp-shops-table td:nth-child(3),
.dsp-shops-table th:nth-child(4),
.dsp-shops-table td:nth-child(4) {
  display: none !important;
}

.dsp-shops-table th:nth-child(1) { width: 32px !important; }
.dsp-shops-table th:nth-child(2) { width: 17% !important; }
.dsp-shops-table th:nth-child(5),
.dsp-shops-table th:nth-child(6) { width: 8% !important; }
.dsp-shops-table th:nth-child(7) { width: 13% !important; }
.dsp-shops-table th:nth-child(8) { width: 20% !important; }
.dsp-shops-table th:nth-child(9) { width: 10% !important; }
.dsp-shops-table th:nth-child(10),
.dsp-shops-table th:nth-child(11) { width: 6% !important; }
.dsp-shops-table th:nth-child(12) { width: 6% !important; }
.dsp-shops-table th:nth-child(13) { width: 8% !important; }
.dsp-shops-table th:nth-child(14) { width: 44px !important; }

.dsp-shops-table th:nth-child(11),
.dsp-shops-table td:nth-child(11),
.dsp-shops-table th:nth-child(13),
.dsp-shops-table td:nth-child(13),
.dsp-shops-table th:nth-child(14),
.dsp-shops-table td:nth-child(14) {
  display: table-cell !important;
}

.dsp-shops-table td.dsp-shop-permission-col {
  width: auto !important;
  min-width: 0 !important;
  text-align: center !important;
}

.dsp-permission-state {
  width: 24px !important;
  height: 24px !important;
  font-size: 12px !important;
}

.dsp-status-approved,
.dsp-status-pending,
.dsp-market-status {
  max-width: 100% !important;
  padding: 4px 6px !important;
  font-size: 7.5px !important;
  line-height: 1.15 !important;
  overflow-wrap: normal !important;
  word-break: keep-all !important;
  writing-mode: horizontal-tb !important;
  white-space: nowrap !important;
}

.dsp-shops-table td.dsp-shop-actions {
  overflow: visible !important;
  padding: 8px 5px !important;
  text-align: center !important;
}

.dsp-shop-action-menu {
  display: inline-block !important;
  width: 32px !important;
  min-width: 32px !important;
  height: 32px !important;
}

.dsp-shop-action-toggle {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 32px !important;
  min-width: 32px !important;
  height: 32px !important;
  min-height: 32px !important;
  padding: 0 !important;
  border: 1px solid #b8d7ca !important;
  border-radius: 8px !important;
  background: #f7fbf9 !important;
  color: #087653 !important;
  box-shadow: none !important;
}

.dsp-shop-action-toggle > span:first-child {
  top: -2px !important;
  font-size: 19px !important;
  font-weight: 600 !important;
}

.dsp-shop-action-toggle:hover,
.dsp-shop-action-toggle:focus,
.dsp-shop-action-menu.is-open .dsp-shop-action-toggle {
  border-color: #087a57 !important;
  background: #087a57 !important;
  color: #fff !important;
}

@media (max-width: 1180px) and (min-width: 761px) {
  .dsp-shops-shell {
    grid-template-columns: 164px minmax(0, 1fr) !important;
    column-gap: 12px !important;
  }

  .dsp-shops-shell > .dsp-shop-sidebar { width: 164px !important; }
  .dsp-shop-sidebar nav b { font-size: 8px !important; }
  .dsp-shops-table th,
  .dsp-shops-table td { padding-left: 4px !important; padding-right: 4px !important; }
  .dsp-shops-table th:nth-child(2) { width: 16% !important; }
  .dsp-shops-table th:nth-child(8) { width: 19% !important; }
}

@media (max-width: 760px) {
  .dsp-shops-shell {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  .dsp-shops-shell > .dsp-shop-sidebar {
    position: sticky !important;
    top: 0 !important;
    width: 100% !important;
    margin: 0 0 10px !important;
    padding: 6px !important;
    overflow-x: auto !important;
    border-radius: 8px !important;
    box-shadow: 0 5px 16px rgba(18, 71, 53, .08) !important;
  }

  .dsp-shop-sidebar-brand,
  .dsp-shop-sidebar-label {
    display: none !important;
  }

  .dsp-shop-sidebar nav {
    display: flex !important;
    width: max-content !important;
    gap: 3px !important;
  }

  .dsp-shop-sidebar nav > a,
  .dsp-shop-sidebar nav > button {
    grid-template-columns: 21px auto auto !important;
    width: auto !important;
    min-height: 32px !important;
    padding: 5px 7px !important;
    white-space: nowrap !important;
  }

  .dsp-shop-sidebar nav b { overflow: visible !important; font-size: 8px !important; }
  .dsp-shop-sidebar nav > a > span,
  .dsp-shop-sidebar nav > button > span { width: 21px !important; height: 21px !important; font-size: 12px !important; }

  .dsp-shops-heading h1 { font-size: 19px !important; }

  .dsp-shops-table tr[data-dsp-shop-search-row] {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    padding: 0 11px !important;
  }

  .dsp-shops-table td:nth-child(3),
  .dsp-shops-table td:nth-child(4) { display: none !important; }

  .dsp-shops-table td:nth-child(5),
  .dsp-shops-table td:nth-child(6),
  .dsp-shops-table td:nth-child(10),
  .dsp-shops-table td:nth-child(11),
  .dsp-shops-table td:nth-child(12),
  .dsp-shops-table td:nth-child(13) {
    display: block !important;
    position: static !important;
    width: auto !important;
    min-width: 0 !important;
    padding: 9px 5px !important;
    border-bottom: 1px solid #edf3ef !important;
  }

  .dsp-shops-table td:nth-child(7),
  .dsp-shops-table td:nth-child(8),
  .dsp-shops-table td:nth-child(9) {
    display: block !important;
    grid-column: 1 / -1 !important;
    position: static !important;
    width: auto !important;
  }

  .dsp-shops-table td:nth-child(10),
  .dsp-shops-table td:nth-child(11) {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    text-align: left !important;
  }

  .dsp-shops-table td:nth-child(10)::before,
  .dsp-shops-table td:nth-child(11)::before {
    display: block !important;
    margin: 0 !important;
  }

  .dsp-shops-table td:nth-child(14) {
    display: block !important;
    position: absolute !important;
    top: 8px !important;
    right: 8px !important;
    width: 32px !important;
    padding: 0 !important;
    border: 0 !important;
    z-index: 20 !important;
  }

  .dsp-shops-table td:nth-child(14)::before { display: none !important; }
  .dsp-shop-action-menu,
  .dsp-shop-action-toggle { width: 32px !important; min-width: 32px !important; height: 32px !important; min-height: 32px !important; }
  .dsp-status-approved,
  .dsp-status-pending,
  .dsp-market-status { font-size: 8px !important; }
}
