/* public/entrance-doors/entrance-product-modal.css */
#entrance-product-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
}
#entrance-product-modal:not(.hidden) {
  opacity: 1;
  visibility: visible;
}

#entrance-product-modal .product-detail-content {
  max-width: 1000px;
  width: 90%;
  padding: 30px;
  padding-top: 55px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  background: white;
  border-radius: 8px;
  box-shadow: 0 5px 25px rgba(0,0,0,0.4);
}

#entrance-product-modal .close {
  position: fixed;
  top: 15px;
  right: 15px;
  z-index: 1001;
  background: #dc3545;
  color: #ffffff;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
  padding: 0;
  border: none;
}
#entrance-product-modal .close:hover {
  color: #a00;
}

.product-detail-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.product-main {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.product-images {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

.detail-image {
  max-width: 100%;
  max-height: 465px;
  object-fit: contain;
  cursor: pointer;
}

.placeholder-image-large {
  width: 100%;
  max-height: 500px;
  background: #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #888;
  font-weight: bold;
  font-size: 1.2rem;
  padding: 20px;
  text-align: center;
}

.product-info {
  flex: 1;
}

.detail-price {
  font-size: 1.8rem;
  font-weight: bold;
  color: #4361ee;
  margin: 10px 0;
}

/* Таблица размеров */
.detail-sizes-table {
  width: 100%;
  margin-top: 15px;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.table-header {
  display: flex;
  background: #f0f5ff;
  font-weight: bold;
  padding: 8px 10px;
  border-bottom: 2px solid #e9ecef;
}

.table-body {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.table-row {
  display: flex;
  align-items: center;
  padding: 6px 10px;
  background: #f8f9fa;
  border-radius: 4px;
  transition: background 0.2s;
  font-size: 0.95rem;
}

.table-row:hover {
  background: #e9ecef;
}

.table-cell {
  flex: 1;
  padding: 3px 5px;
  text-align: left;
  vertical-align: middle;
}

.table-cell.size-cell,
.table-cell.price-cell,
.table-cell.item-cell,
.table-cell.stock-cell {
  text-align: left;
  vertical-align: middle !important;
}

.size-header, .size-cell { flex: 1.3; }
.price-header, .price-cell { flex: 1; }
.item-header, .item-cell { flex: 1; color: #6c757d; font-size: 0.85rem; }
.stock-header, .stock-cell { flex: 1; }
.actions-header, .actions-cell { flex: 1; text-align: right; }

.item-cell { color: #495057; font-size: 0.85rem; }

.stock-cell.available { color: #38b000; }
.stock-cell.unavailable { color: #d90429; }

.stock-cell {
  flex: 1;
  text-align: left;
  white-space: nowrap; 
  overflow: hidden;
  text-overflow: ellipsis;
}

.hover-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  opacity: 0;
  transition: opacity 0.3s;
}
.table-row:hover .hover-actions { opacity: 1; }

/* Стили для таблицы характеристик */
.product-specs {
  margin-top: 25px;
  padding-top: 20px;
  border-top: 1px solid #eee;
}

.product-specs h3 {
  color: #4361ee;
  margin-bottom: 12px;
  font-size: 1.2rem;
}

.product-specs {
  background: #f8f9fa;
  border-radius: 8px;
  padding: 20px;
}

.product-specs h3 {
  margin-top: 0;
  color: #2c3e50;
  font-size: 1.3rem;
  border-bottom: 2px solid #4361ee;
  padding-bottom: 8px;
  margin-bottom: 16px;
}

.specs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.spec-column {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.spec-item {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

/* Для статусов в таблице размеров — разбивка на две строки */
.expected-delivery {
  white-space: normal !important;
  word-break: keep-all;
  display: inline-block;
  line-height: 1.3;
}
.expected-delivery span {
  display: block;
}
.spec-label {
  font-size: 0.9rem;
  color: #6c757d;
  white-space: nowrap;
}
.spec-value {
  font-weight: 500;
  color: #212529;
  text-align: right;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Уведомление о товарах под заказ (если понадобится) */
.out-of-stock-notice {
  background-color: #fff3cd;
  border: 1px solid #ffeaa7;
  color: #856404;
  padding: 8px;
  margin-bottom: 10px;
  border-radius: 4px;
  font-size: 0.85rem;
}