.imm-box-builder-container {
  width: 100% !important;
  display: block !important;
  clear: both !important;
  margin: 25px 0 !important;
  padding: 20px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
}

.imm-status-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #f8fafc;
  padding: 15px 20px;
  border-radius: 6px;
  margin-bottom: 20px;
  border: 1px solid #e2e8f0;
  flex-wrap: wrap;
  gap: 10px;
}

.imm-progress-wrapper {
  flex: 1;
  min-width: 200px;
}

.imm-progress-bar {
  width: 100%;
  max-width: 300px;
  height: 8px;
  background: #e2e8f0;
  border-radius: 4px;
  overflow: hidden;
  margin-top: 4px;
}

#imm-progress-fill {
  height: 100%;
  background: #629759; /* Green active branding slider accent */
  width: 0%;
  transition: width 0.2s ease;
}

.imm-action-summary {
  text-align: right;
}

.imm-price-summary {
  font-size: 16px;
  color: #334155;
}
.imm-price-summary strong {
  font-size: 20px;
  color: #0f172a;
}

/* Premium Rows Stack System Architecture */
.imm-products-list {
  display: flex;
  flex-direction: column;
  width: 100% !important;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #ffffff;
  overflow: hidden;
}

.imm-product-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid #e2e8f0;
  transition: background 0.2s ease;
}

.imm-product-row:last-child {
  border-bottom: none;
}

.imm-product-row:hover {
  background: #f8fafc;
}

.imm-row-left {
  display: flex;
  align-items: center;
  gap: 15px;
  flex: 1;
}

/* Defensively force layout sizing for the thumbnail container */
.imm-row-image {
  width: 60px !important;
  height: 60px !important;
  flex-shrink: 0 !important; /* Stops the container from collapsing on small screens */
  display: block !important;
}

/* Enforce proportional scaling and aspect ratio on the image tag */
.imm-row-image img {
  width: 100% !important;
  height: 100% !important;
  max-width: 60px !important;
  max-height: 60px !important;
  object-fit: cover !important; /* Crops the image dynamically instead of squishing it */
  object-position: center !important;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
  display: block !important;
  box-shadow: none !important;
}

.imm-row-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.imm-row-title {
  font-size: 15px;
  font-weight: 600;
  color: #1e293b;
  margin: 0 !important;
}

.imm-attributes-wrapper {
  font-size: 13px;
  color: #64748b;
}

.imm-stock-badge {
  color: #22c55e;
  font-weight: 500;
  font-size: 12px;
}

/* Defensively enforce inline structural positioning */
.imm-row-right {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  min-width: 120px !important;
  flex-shrink: 0 !important;
}

.imm-quantity-controls {
  display: inline-flex !important;
  flex-direction: row !important; /* Forces layout left-to-right */
  align-items: center !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 4px !important;
  overflow: hidden !important;
  height: 32px !important;
  width: auto !important; /* Overrides theme 100% full-width inheritance */
  background: #ffffff !important;
}

/* Neutralize aggressive theme button expansions */
.imm-qty-btn {
  background: #f1f5f9 !important;
  border: none !important;
  width: 32px !important;
  height: 32px !important; /* Strict fixed dimensional squares */
  cursor: pointer !important;
  font-size: 14px !important;
  font-weight: bold !important;
  padding: 0 !important;
  margin: 0 !important;
  color: #334155 !important;
  line-height: 32px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: none !important; /* Strips premium theme button accents */
  min-height: 0 !important;
}

.imm-qty-btn:hover {
  background: #e2e8f0 !important;
}

/* Strip global WooCommerce template spinner rules */
.imm-item-qty {
  width: 40px !important;
  height: 32px !important;
  text-align: center !important;
  border: none !important;
  border-left: 1px solid #cbd5e1 !important;
  border-right: 1px solid #cbd5e1 !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  padding: 0 !important;
  margin: 0 !important;
  background: #ffffff !important;
  box-shadow: none !important;
  -moz-appearance: textfield !important;
}

/* Explicitly target and strip native webkit micro-increment spinners */
.imm-item-qty::-webkit-outer-spin-button,
.imm-item-qty::-webkit-inner-spin-button {
  -webkit-appearance: none !important;
  margin: 0 !important;
}

/* ==========================================================================
   IN-CART EDIT SELECTIONS LINK BUTTON STYLES
   ========================================================================== */

.imm-cart-title-edit-wrapper {
  margin-top: 8px !important;
  display: block !important;
  width: 100% !important;
  clear: both !important;
}

.imm-cart-edit-btn {
  display: inline-block !important;
  background-color: #446084 !important; /* Premium production theme blue */
  color: #ffffff !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: 0.04em !important;
  padding: 6px 14px !important;
  line-height: 1.3 !important;
  border-radius: 3px !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  text-align: center !important;
  border: none !important;
  box-shadow: none !important;
  transition: background-color 0.2s ease-in-out !important;
  height: auto !important;
  min-height: 0 !important;
  white-space: nowrap !important; /* Defends against vertical column compression wrapping */
  width: auto !important;
}

.imm-cart-edit-btn:hover {
  background-color: #2c3e56 !important;
  color: #ffffff !important;
}
