/* ===== PROVADOR VIRTUAL ===== */

.virtual-fitter {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 15px;
  background: #f9f9f9;
  border-radius: 8px;
  margin: 10px 0;
}

.fitter-viewer {
  width: 100%;
  background: #ffffff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.fitter-image-container {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.fitter-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 20px;
}

.fitter-controls {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  display: flex;
  justify-content: space-between;
  padding: 0 15px;
  pointer-events: none;
}

.fitter-btn {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(0, 20, 137, 0.8);
  color: white;
  border: none;
  font-size: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
  pointer-events: all;
}

.fitter-btn:hover {
  background: rgba(0, 20, 137, 1);
  transform: scale(1.1);
}

.fitter-indicators {
  position: absolute;
  bottom: 15px;
  right: 15px;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 8px 12px;
  border-radius: 20px;
  font-size: 12px;
}

.indicator-text {
  font-weight: 600;
}

/* Seletor de Cores */
.color-selector {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.color-label {
  font-size: 14px;
  font-weight: 600;
  color: #333;
  margin: 0;
}

.color-options {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.color-name {
  font-size: 13px;
  color: #666;
  margin: 0;
  font-weight: 500;
}

.color-btn {
  width: 50px;
  height: 50px;
  border-radius: 8px;
  border: 3px solid transparent;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.color-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.color-btn.active {
  border-color: #001489;
  box-shadow: 0 0 0 2px rgba(0, 20, 137, 0.3);
}

/* Botões de Ação */
.fitter-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-measurements,
.btn-virtual-fitter {
  flex: 1;
  min-width: 150px;
  padding: 12px 20px;
  border: 2px solid #001489;
  background: white;
  color: #001489;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}

.btn-virtual-fitter {
  background: #001489;
  color: white;
}

.btn-measurements:hover {
  background: #f0f0f0;
}

.btn-virtual-fitter:hover {
  background: #0033cc;
}

/* ===== MODAL DE MEDIDAS ===== */

.modal-measurements {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal-content {
  background: white;
  border-radius: 10px;
  max-width: 900px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 40px;
  height: 40px;
  border: none;
  background: #f0f0f0;
  border-radius: 50%;
  font-size: 28px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
  z-index: 10;
}

.modal-close:hover {
  background: #e0e0e0;
}

.modal-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  padding: 40px;
}

.modal-image {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f5;
  border-radius: 10px;
  padding: 20px;
}

.modal-image img {
  width: 100%;
  height: auto;
  max-height: 400px;
  object-fit: contain;
}

.modal-table {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.modal-table h2 {
  margin: 0;
  font-size: 20px;
  color: #001489;
}

.measurements-table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid #ddd;
}

.measurements-table th {
  background: #001489;
  color: white;
  padding: 12px;
  text-align: left;
  font-weight: 600;
}

.measurements-table td {
  padding: 12px;
  border-bottom: 1px solid #ddd;
}

.measurements-table tr:hover {
  background: #f9f9f9;
}

.modal-info {
  font-size: 13px;
  color: #666;
  margin: 10px 0;
}

.modal-link {
  color: #001489;
  text-decoration: none;
  font-weight: 600;
  display: inline-block;
  margin: 5px 0;
}

.modal-link:hover {
  text-decoration: underline;
}

.modal-unit {
  font-size: 12px;
  color: #999;
  margin: 10px 0 0 0;
}

/* ===== CALCULADORA DE FRETE ===== */

.shipping-calculator {
  background: transparent;
  padding: 0;
  border-radius: 0;
  margin: 0;
  margin-top: -5px;
}

.shipping-calculator h3 {
  font-size: 14px;
  margin: 0 0 8px 0;
  color: #333;
  font-weight: 600;
}

.cep-input-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cep-input-group label {
  display: none;
}

.cep-input-container {
  display: flex;
  gap: 5px;
}

.cep-input {
  flex: 1;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 13px;
  transition: border-color 0.3s;
  background: #fff;
  height: 40px;
}

.cep-input:focus {
  outline: none;
  border-color: #001489;
}

.btn-calculate {
  padding: 0 15px;
  background: #333;
  color: white;
  border: none;
  border-radius: 4px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  text-transform: uppercase;
  height: 40px;
}

.btn-calculate:hover {
  background: #0033cc;
}

.error-message {
  color: #d32f2f;
  font-size: 13px;
  min-height: 20px;
}

.loading-spinner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 15px;
  padding: 30px;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #f0f0f0;
  border-top-color: #001489;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.shipping-results {
  margin-top: 8px;
  padding: 0;
  background: transparent;
  border-radius: 0;
}

.shipping-options-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 0;
}

.shipping-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid #eee;
  border-radius: 4px;
  background: #fff;
  transition: all 0.2s;
}

.shipping-option.active {
  border-color: #001489;
  background: #f0f4ff;
}

.shipping-info {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.shipping-name {
  font-weight: 600;
  color: #333;
  font-size: 13px;
  flex: 1;
}

.shipping-price {
  font-size: 13px;
  font-weight: bold;
  color: #001489;
  margin: 0 10px;
}

.shipping-days {
  font-size: 12px;
  color: #666;
  white-space: nowrap;
}

.address-details {
  padding: 12px;
  background: #f5f5f5;
  border-radius: 8px;
  border-left: 4px solid #001489;
  display: none;
}

.address-details p {
  margin: 6px 0;
  font-size: 12px;
  color: #333;
}

/* Responsivo */
@media (max-width: 768px) {
  .modal-body {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 20px;
  }
  
  .fitter-controls {
    padding: 0 10px;
  }
  
  .fitter-btn {
    width: 40px;
    height: 40px;
    font-size: 18px;
  }
  
  .cep-input-container {
    flex-direction: column;
  }
  
  .btn-calculate {
    width: 100%;
  }
  
  .color-options {
    gap: 8px;
  }
  
  .color-btn {
    width: 40px;
    height: 40px;
  }
}
