#wpcontent,
#wpfooter {
  margin-left: 0 !important;
}
html,
body {
  margin: 0 !important;
  padding: 0 !important;
}

#wpbody-content {
  padding-bottom: 0;
}
#wpfooter {
  display: none !important;
}

#wpbody-content {
  padding-bottom: 0 !important;
}
#adminmenu,
#adminmenuback,
#adminmenuwrap {
  display: none !important;
}

html.wp-toolbar {
  padding-top: 0 !important;
}

#wpadminbar {
  display: none !important;
}

.prep-admin-layout {
  display: flex;
  min-height: 100vh;
  background: #f5f6fa;
}

.prep-sidebar {
  width: 260px;
  background: #111827;
  color: #fff;
  display: flex;
  flex-direction: column;
  padding: 24px 0;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
}

.prep-logo {
  padding: 0 24px 30px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.prep-logo h2 {
  margin: 0;
  color: #fff;
  font-size: 24px;
  font-weight: 700;
}

.prep-logo span {
  color: #9ca3af;
  font-size: 13px;
}

.prep-nav {
  padding: 24px 12px;
  flex: 1;
}

.prep-nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #d1d5db;
  text-decoration: none;
  padding: 14px 16px;
  border-radius: 10px;
  margin-bottom: 6px;
  transition: 0.2s;
  font-size: 14px;
  font-weight: 500;
}

.prep-nav a:hover,
.prep-nav a.active {
  background: #e8571a;
  color: #fff;
}

.prep-sidebar-footer {
  padding: 20px 12px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.prep-sidebar-footer a {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #d1d5db;
  text-decoration: none;
  padding: 14px 16px;
  border-radius: 10px;
}
.prep-sidebar-footer a:hover {
  color: #d1d5dbc7;
}
.prep-main-content {
  margin-left: 260px;
  width: calc(100% - 260px);
  padding: 30px;
}

.shipment-dashboard {
  max-width: 1400px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.sd-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #fff;
  padding: 20px 30px;
  margin: -30px -30px 24px -30px;
  border-bottom: 1px solid #e5e7eb;
}

.sd-topbar h1 {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  color: #1a1a2e;
}

.sd-view-site {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #e8571a;
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
}

.sd-view-site:hover {
  color: #c94a16;
  text-decoration: underline;
}
.sd-view-site .dashicons {
  font-size: 16px;
}

.sd-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 20px 0 20px;
}

.sd-card {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  padding: 18px 20px 16px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.sd-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
}

.sd-icon {
  font-size: 22px;
  color: #e8571a;
  background: #fff0e8;
  border-radius: 8px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sd-card-top .sd-icon {
  display: inline-block;
  line-height: 40px;
  text-align: center;
}

.sd-change {
  font-size: 11px;
  font-weight: 600;
  border-radius: 4px;
  padding: 2px 6px;
}

.sd-up {
  color: #27ae60;
  background: #eafaf1;
}
.sd-down {
  color: #e74c3c;
  background: #fdedec;
}

.sd-value {
  font-size: 28px;
  font-weight: 700;
  color: #1a1a2e;
  line-height: 1.1;
  margin-bottom: 4px;
}

.sd-label {
  font-size: 12px;
  color: #999;
  letter-spacing: 0.3px;
}

.sd-orange {
  color: #e8571a !important;
}
.sd-green {
  color: #27ae60 !important;
}
.sd-yellow {
  color: #f39c12 !important;
}

.sd-section {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  padding: 20px 22px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.sd-section h2 {
  margin: 0 0 16px;
  font-size: 16px;
  font-weight: 700;
  color: #1a1a2e;
}

.sd-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.sd-section-header h2 {
  margin: 0;
}

.sd-view-all {
  color: #e8571a;
  text-decoration: none;
  font-size: 12px;
  font-weight: 600;
}

.sd-view-all:hover {
  color: #c94a16;
}

.sd-empty {
  color: #aaa;
  font-size: 13px;
  margin: 20px 0;
  text-align: center;
}

.sd-middle-row {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 16px;
  margin-bottom: 16px;
  align-items: start;
}

.sd-table {
  border: none !important;
  border-collapse: collapse;
  width: 100%;
}

.sd-table thead th {
  background: #fafafa !important;
  font-weight: 600;
  font-size: 12px;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 9px 12px;
  border-bottom: 1px solid #eee;
}

.sd-table td {
  padding: 10px 12px;
  font-size: 13px;
  color: #333;
  border-bottom: 1px solid #f5f5f5;
  vertical-align: middle;
}

.sd-table tr:last-child td {
  border-bottom: none;
}
.sd-table.striped tr:nth-child(odd) td {
  background: #fafafa;
}

.sd-tracking-link {
  color: #e8571a;
  font-weight: 600;
  text-decoration: none;
  font-size: 12px;
  font-family: monospace;
  letter-spacing: 0.3px;
}

.sd-tracking-link:hover {
  color: #c94a16;
  text-decoration: underline;
}

.sd-dest,
.sd-eta {
  display: flex;
  align-items: center;
  gap: 4px;
  color: #555;
}

.sd-dest .dashicons,
.sd-eta .dashicons {
  font-size: 14px;
  color: #aaa;
}

.sd-status {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.sd-status-in-transit {
  background: #ebf5fb;
  color: #2980b9;
}
.sd-status-delivered {
  background: #eafaf1;
  color: #27ae60;
}
.sd-status-processing {
  background: #fef9e7;
  color: #f39c12;
}

.sd-customers-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.sd-customer-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid #f5f5f5;
}

.sd-customer-row:last-child {
  border-bottom: none;
}

.sd-rank {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #e8571a;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sd-customer-info {
  flex: 1;
  min-width: 0;
}

.sd-customer-info strong {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #1a1a2e;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sd-customer-info span {
  font-size: 11px;
  color: #999;
}

.sd-customer-revenue {
  font-size: 13px;
  font-weight: 700;
  color: #e8571a;
  flex-shrink: 0;
}

.sd-bottom-row {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 16px;
  margin-bottom: 24px;
  align-items: start;
}

.sd-dist-row {
  display: grid;
  grid-template-columns: 110px 1fr 90px;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}

.sd-dist-row:last-child {
  margin-bottom: 0;
}

.sd-dist-label {
  font-size: 13px;
  font-weight: 600;
  color: #333;
}

.sd-dist-count {
  font-size: 12px;
  color: #888;
  text-align: right;
  white-space: nowrap;
}

.sd-bar-wrap {
  background: #f0f0f0;
  border-radius: 4px;
  height: 8px;
  overflow: hidden;
}

.sd-bar {
  height: 100%;
  border-radius: 4px;
  transition: width 0.4s ease;
}

.sd-bar-blue {
  background: #2980b9;
}
.sd-bar-green {
  background: #27ae60;
}
.sd-bar-yellow {
  background: #f39c12;
}

.sd-quick-actions h2 {
  margin-bottom: 14px;
}

.sd-actions-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.sd-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #fff0e8;
  color: #e8571a;
  border: 1px solid #fad5bf;
  border-radius: 10px;
  padding: 18px 12px;
  font-weight: 600;
  text-decoration: none;
  font-size: 12px;
  text-align: center;
  transition:
    background 0.18s,
    color 0.18s,
    border-color 0.18s;
}

.sd-action-btn:hover {
  background: #e8571a;
  color: #fff;
  border-color: #e8571a;
}

.sd-action-btn .dashicons {
  font-size: 24px;
  width: 24px;
  height: 24px;
}

.prep-mobile-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 998;
  opacity: 0;
  visibility: hidden;
  transition: 0.25s;
}

.prep-mobile-overlay.active {
  opacity: 1;
  visibility: visible;
}

.prep-menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: none;
  background: #fff;
  border-radius: 10px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.prep-menu-toggle .dashicons {
  font-size: 22px;
  width: 22px;
  height: 22px;
  color: #111827;
}

.prep-close-sidebar {
  display: none;
  border: none;
  background: transparent;
  color: #fff;
  cursor: pointer;
}

.prep-close-sidebar .dashicons {
  font-size: 24px;
  width: 24px;
  height: 24px;
}

.prep-logo-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.sd-topbar-left {
  display: flex;
  align-items: center;
  gap: 14px;
}
.sd-topbar-right a {
  color: #1a1a1a;
  font-size: 18px;
}
.sd-topbar-right a:hover {
  color: #ff6600;
}

body.prep-sidebar-open {
  overflow: hidden;
}

body.page-template-client-dashboard .prep-sidebar {
  transform: translateX(0) !important;
}

body.page-template-client-dashboard .prep-main-content {
  margin-left: 260px !important;
  width: calc(100% - 260px) !important;
}

body.page-template-client-dashboard .prep-menu-toggle {
  display: none !important;
}

body.page-template-client-dashboard .prep-close-sidebar {
  display: none !important;
}
@media (min-width: 1025px) {
  .prep-client-layout .prep-sidebar {
    transform: translateX(0) !important;
  }

  .prep-client-layout .prep-main-content {
    margin-left: 260px !important;
    width: calc(100% - 260px) !important;
  }

  .prep-client-layout .prep-menu-toggle,
  .prep-client-layout .prep-close-sidebar {
    display: none !important;
  }
}
@media (max-width: 1100px) {
  .sd-cards {
    grid-template-columns: repeat(2, 1fr);
  }
  .sd-middle-row,
  .sd-bottom-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1024px) {
  .prep-sidebar {
    transform: translateX(-100%);
    transition: 0.3s ease;
    z-index: 999;
  }

  .prep-sidebar.active {
    transform: translateX(0);
  }

  .prep-main-content {
    margin-left: 0;
    width: 100%;
    padding: 20px;
  }

  .prep-menu-toggle {
    display: flex;
  }

  .prep-close-sidebar {
    display: block;
  }

  .sd-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .sd-middle-row,
  .sd-bottom-row {
    grid-template-columns: 1fr;
  }

  .sd-section {
    overflow: hidden;
  }

  .sd-table {
    min-width: 700px;
  }

  .sd-section {
    overflow-x: auto;
  }
}

@media (max-width: 640px) {
  .sd-cards {
    grid-template-columns: 1fr;
  }

  .prep-main-content {
    padding: 14px;
  }

  .sd-topbar {
    padding: 16px;
    margin: -14px -14px 20px -14px;
    gap: 12px;
    flex-wrap: wrap;
  }

  .sd-topbar h1 {
    font-size: 20px;
  }

  .sd-cards {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .sd-card {
    padding: 16px;
  }

  .sd-value {
    font-size: 24px;
  }

  .sd-actions-grid {
    grid-template-columns: 1fr;
  }

  .sd-dist-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .sd-dist-count {
    text-align: left;
  }

  .sd-customer-row {
    align-items: flex-start;
  }

  .prep-sidebar {
    width: 280px;
  }

  .sd-view-site {
    width: 100%;
    justify-content: flex-start;
  }
}
