/* === MODAL DE PEDIDO === */
.order-modal-box {
  background: #fff;
  border-radius: 14px;
  padding: 28px;
  width: 96vw;
  max-width: 900px;
  max-height: 92vh;
  overflow-y: auto;
  box-shadow: 0 12px 48px rgba(0,0,0,.25);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.order-modal-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.order-modal-left,
.order-modal-right {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* === ITENS DO PEDIDO === */
.order-items-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 600;
  color: #444;
  padding-bottom: 6px;
  border-bottom: 1px solid #eee;
}

.order-items-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 260px;
  overflow-y: auto;
  padding-right: 2px;
}

.order-items-empty {
  text-align: center;
  color: #ccc;
  font-size: 13px;
  padding: 24px 0;
}

.order-item-row {
  display: grid;
  grid-template-columns: 1fr 70px 90px 32px;
  align-items: center;
  gap: 6px;
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 8px 10px;
}

.order-item-name {
  font-size: 13px;
  font-weight: 600;
  color: #222;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.order-item-code {
  font-size: 11px;
  color: #aaa;
}

.order-item-qty {
  width: 100%;
  padding: 5px 6px;
  border: 1.5px solid #ddd;
  border-radius: 6px;
  font-size: 13px;
  text-align: center;
  outline: none;
}
.order-item-qty:focus { border-color: #c0000c; }

.order-item-price {
  width: 100%;
  padding: 5px 6px;
  border: 1.5px solid #ddd;
  border-radius: 6px;
  font-size: 12px;
  text-align: right;
  outline: none;
}
.order-item-price:focus { border-color: #c0000c; }

.order-item-remove {
  background: none;
  border: none;
  color: #ccc;
  font-size: 18px;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  transition: color .15s;
}
.order-item-remove:hover { color: #c0000c; }

.order-total-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background: #fafafa;
  border: 1.5px solid #eee;
  border-radius: 8px;
  font-size: 14px;
  color: #444;
}
.order-total-row strong {
  font-size: 18px;
  font-weight: 800;
  color: #c0000c;
}

/* === STATUS BADGES === */
.status-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  white-space: nowrap;
}
.status-pendente    { background: #fff8e1; color: #f57f17; }
.status-em_separacao { background: #fff3e0; color: #e65100; }
.status-confirmado { background: #e3f2fd; color: #1565c0; }
.status-enviado    { background: #f3e5f5; color: #6a1b9a; }
.status-entregue   { background: #e8f5e9; color: #2e7d32; }
.status-cancelado  { background: #ffeaea; color: #c0000c; }

/* === DETALHES DO PEDIDO === */
.order-detail-section {
  margin-bottom: 16px;
}
.order-detail-section h3 {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: #aaa;
  margin-bottom: 8px;
}
.order-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 16px;
  font-size: 13px;
  color: #444;
}
.order-detail-grid span { color: #888; font-size: 12px; }

.order-detail-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.order-detail-table th {
  text-align: left;
  padding: 6px 10px;
  border-bottom: 2px solid #f0f0f0;
  font-size: 11px;
  text-transform: uppercase;
  color: #aaa;
}
.order-detail-table td {
  padding: 8px 10px;
  border-bottom: 1px solid #f5f5f5;
}
.order-detail-total {
  display: flex;
  justify-content: flex-end;
  gap: 16px;
  align-items: center;
  padding: 12px 10px 4px;
  font-size: 15px;
  font-weight: 700;
  color: #c0000c;
}

/* === STATUS DROPDOWN NA TABELA === */
.status-select {
  border: none;
  background: transparent;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  outline: none;
  padding: 3px 6px;
  border-radius: 20px;
}

/* === RESPONSIVE === */
@media (max-width: 700px) {
  .order-modal-body { grid-template-columns: 1fr; }
  .order-modal-box { padding: 16px; max-height: 95vh; }
  .order-detail-grid { grid-template-columns: 1fr; }
}
