/* ==========================================================================
   CRIA3D - COMPONENTES VISUAIS & WIZARD EM ABAS
   ========================================================================== */

/* ==========================================================================
   BOTÕES E ELEMENTOS DE AÇÃO
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 24px;
  border-radius: var(--radius-full);
  font-family: var(--font-title);
  font-size: 0.96rem;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: var(--transition);
  min-height: 46px; /* Acessibilidade de toque */
  line-height: 1;
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--primary);
  color: white;
  box-shadow: 0 4px 14px rgba(201, 139, 94, 0.3);
}
.btn-primary:hover {
  background: var(--primary-hover);
  color: white;
  box-shadow: 0 6px 18px rgba(201, 139, 94, 0.4);
}

.btn-secondary {
  background: var(--secondary);
  color: white;
  box-shadow: 0 4px 14px rgba(143, 166, 138, 0.28);
}
.btn-secondary:hover {
  background: var(--secondary-hover);
  color: white;
}

.btn-outline {
  background: transparent;
  border-color: var(--border-medium);
  color: var(--text-main);
}
.btn-outline:hover {
  background: var(--bg-surface-alt);
  border-color: var(--text-muted);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
}
.btn-ghost:hover {
  color: var(--text-main);
  background: rgba(0, 0, 0, 0.04);
}

.btn-sm {
  padding: 8px 16px;
  font-size: 0.86rem;
  min-height: 38px;
}

.btn-lg {
  padding: 15px 32px;
  font-size: 1.05rem;
  min-height: 52px;
}

.btn-full {
  width: 100%;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

/* ==========================================================================
   CARDS E SUPERFÍCIES
   ========================================================================== */
.card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--border-medium);
}

.card-elevated {
  background: var(--bg-surface-elevated);
  box-shadow: var(--shadow-md);
}

/* Badges e Pílulas */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.badge-terracota {
  background: var(--primary-light);
  color: var(--primary);
  border: 1px solid var(--primary-light-border);
}

.badge-sage {
  background: var(--secondary-light);
  color: var(--secondary-hover);
}

.badge-success {
  background: var(--success-bg);
  color: var(--success);
}

/* ==========================================================================
   ABA INÍCIO (HERO & DESTAQUES)
   ========================================================================== */
.hero-section {
  padding: 50px 0 60px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 40px;
  align-items: center;
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.hero-tag {
  align-self: flex-start;
}

.hero-title {
  color: var(--text-main);
  line-height: 1.15;
}

.hero-title em {
  font-style: normal;
  color: var(--primary);
  position: relative;
}

.hero-description {
  font-size: 1.08rem;
  color: var(--text-muted);
  max-width: 540px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.hero-trust-badges {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-top: 16px;
  padding-top: 20px;
  border-top: 1px solid var(--border-subtle);
  flex-wrap: wrap;
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.86rem;
  color: var(--text-muted);
  font-weight: 500;
}

.trust-item svg {
  color: var(--primary);
  flex-shrink: 0;
}

/* Card Visual Interativo no Hero */
.hero-interactive-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.hero-preview-box {
  width: 100%;
  height: 260px;
  background: linear-gradient(180deg, #F9F4EB 0%, #EFE8DC 100%);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border-subtle);
}

.hero-model-svg {
  width: 140px;
  height: 140px;
  filter: drop-shadow(0 12px 24px rgba(59, 50, 38, 0.15));
  animation: floatSlow 4s ease-in-out infinite alternate;
}

@keyframes floatSlow {
  0% { transform: translateY(0px) rotate(0deg); }
  100% { transform: translateY(-8px) rotate(3deg); }
}

.hero-preview-specs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 18px;
  text-align: center;
}

.spec-box {
  background: var(--bg-surface-alt);
  padding: 10px;
  border-radius: var(--radius-sm);
}

.spec-label {
  font-size: 0.72rem;
  color: var(--text-light);
  text-transform: uppercase;
  font-weight: 600;
}

.spec-val {
  font-family: var(--font-title);
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text-main);
}

/* Seção de Passos Simples */
.steps-section {
  padding: 50px 0;
  background: var(--bg-surface-warm);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.section-header {
  text-align: center;
  max-width: 620px;
  margin: 0 auto 36px;
}

.section-header p {
  margin-top: 8px;
  font-size: 1rem;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.step-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 28px 22px;
  text-align: center;
  position: relative;
  transition: var(--transition);
}

.step-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.step-number {
  width: 44px;
  height: 44px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-title);
  font-size: 1.2rem;
  font-weight: 800;
  margin: 0 auto 16px;
  border: 1px solid var(--primary-light-border);
}

.step-card h4 {
  margin-bottom: 10px;
}

/* ==========================================================================
   ABA ORÇAMENTO / CALCULADORA PASSO A PASSO
   ========================================================================== */
.calc-container {
  padding: 30px 0 60px;
}

/* ==========================================================================
   SELETOR DE MODO DE ORÇAMENTO (COM ARQUIVO OU POR MEDIDAS)
   ========================================================================== */
.calc-mode-switch-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.calc-mode-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  border-radius: var(--radius-full);
  background: var(--bg-surface);
  border: 2px solid var(--border-medium);
  color: var(--text-muted);
  font-family: var(--font-title);
  font-size: 0.96rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  min-height: 52px;
  box-shadow: var(--shadow-xs);
}

.calc-mode-btn:hover {
  border-color: var(--primary);
  background: var(--bg-surface-alt);
  color: var(--text-main);
}

.calc-mode-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: 0 6px 20px rgba(201, 139, 94, 0.35);
}

.calc-mode-btn .mode-badge-rec {
  background: var(--secondary);
  color: white;
  font-size: 0.72rem;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-weight: 800;
  text-transform: uppercase;
}

.calc-mode-btn.active .mode-badge-rec {
  background: #FFF;
  color: var(--primary);
}

/* ==========================================================================
   FORMULÁRIO DE ORÇAMENTO RÁPIDO POR MEDIDAS (SEM ARQUIVO 3D)
   ========================================================================== */
.quick-calc-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 40px;
}

.quick-calc-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 36px;
  align-items: start;
}

/* Tipos de Projeto Rápido */
.quick-type-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
  margin-bottom: 24px;
}

.quick-type-btn {
  background: var(--bg-surface-alt);
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 14px 10px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-family: var(--font-title);
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--text-main);
}

.quick-type-btn:hover {
  border-color: var(--border-medium);
  background: var(--bg-surface-warm);
}

.quick-type-btn.active {
  border-color: var(--primary);
  background: var(--primary-light);
  color: var(--primary);
}

.quick-type-btn .type-icon {
  font-size: 1.6rem;
}

/* Presets de Tamanho (P, M, G, GG) */
.size-presets-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}

.size-preset-card {
  background: var(--bg-surface);
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 14px 8px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
}

.size-preset-card:hover {
  border-color: var(--border-medium);
}

.size-preset-card.active {
  border-color: var(--primary);
  background: var(--primary-light);
}

.size-tag-letter {
  font-family: var(--font-title);
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--primary);
  line-height: 1;
}

.size-tag-dim {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-main);
  margin: 4px 0 2px;
}

.size-tag-example {
  font-size: 0.72rem;
  color: var(--text-light);
  line-height: 1.2;
}

/* Níveis de Detalhe */
.detail-levels-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

.detail-level-card {
  background: var(--bg-surface);
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 16px 12px;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
}

.detail-level-card:hover {
  border-color: var(--border-medium);
}

.detail-level-card.active {
  border-color: var(--secondary);
  background: var(--secondary-light);
}

.detail-title {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-main);
  margin-bottom: 4px;
}

.detail-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.3;
}

/* Estado desativado / indisponível (meio transparente) */
.detail-level-card.disabled,
.quality-choice-card.disabled {
  opacity: 0.52 !important;
  filter: grayscale(35%);
  cursor: not-allowed !important;
  border-style: dashed !important;
  border-color: var(--border-medium) !important;
  background: rgba(244, 237, 224, 0.45) !important;
  position: relative;
  pointer-events: none; /* Impede clique */
}

.badge-unavailable {
  display: inline-block;
  background: #E4D9C8;
  color: #756857;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-top: 4px;
}

/* Aviso de limite de tamanho da Bambu Lab A1 Mini (18x18x18 cm) */
.size-warning-box {
  background: #FFF6EC;
  border: 1px solid #F5C68A;
  color: #8A4F1D;
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 0.84rem;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  line-height: 1.4;
}

.size-warning-box.hidden {
  display: none !important;
}

/* Card de Resultado da Estimativa Rápida (Coluna Direita) */
.quick-estimate-result-card {
  background: linear-gradient(145deg, #FFFDF8 0%, #FAF4EA 100%);
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-md);
  position: sticky;
  top: 90px;
}

.estimate-header {
  text-align: center;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 18px;
}

.estimate-price-range {
  font-family: var(--font-title);
  font-size: 2.1rem;
  font-weight: 800;
  color: var(--primary);
  margin: 6px 0;
  line-height: 1.1;
}

.estimate-specs-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.9rem;
  margin-bottom: 22px;
}

.estimate-spec-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-muted);
}

.estimate-spec-row strong {
  color: var(--text-main);
}


/* Barra de Progresso das Etapas */
.wizard-progress-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 30px;
  position: relative;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.wizard-progress-track {
  position: absolute;
  top: 18px;
  left: 30px;
  right: 30px;
  height: 3px;
  background: var(--border-medium);
  z-index: 1;
}

.wizard-progress-fill {
  height: 100%;
  background: var(--primary);
  width: 0%;
  transition: width 0.35s ease;
}

.wizard-step-node {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0 4px;
}

.node-circle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 2px solid var(--border-medium);
  color: var(--text-muted);
  font-weight: 700;
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.wizard-step-node.active .node-circle {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
  box-shadow: 0 0 0 4px var(--primary-light);
}

.wizard-step-node.completed .node-circle {
  background: var(--secondary);
  border-color: var(--secondary);
  color: white;
}

.node-label {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
}

.wizard-step-node.active .node-label {
  color: var(--primary);
  font-weight: 700;
}

/* Layout Principal da Calculadora (Duas Colunas no Desktop) */
.calc-layout {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 32px;
  align-items: start;
}

/* Painel de Etapas */
.calc-wizard-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
}

.calc-step-panel {
  display: none;
  animation: fadeIn 0.25s ease;
}

.calc-step-panel.active {
  display: block;
}

.step-panel-title {
  margin-bottom: 6px;
}

.step-panel-desc {
  font-size: 0.92rem;
  margin-bottom: 24px;
}

/* Área de Upload Drag & Drop */
.upload-dropzone {
  border: 2px dashed var(--border-medium);
  border-radius: var(--radius-md);
  padding: 40px 20px;
  text-align: center;
  background: var(--bg-surface-alt);
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}

.upload-dropzone:hover,
.upload-dropzone.drag-over {
  border-color: var(--primary);
  background: var(--primary-light);
}

.upload-icon {
  width: 52px;
  height: 52px;
  background: var(--bg-surface);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  color: var(--primary);
  box-shadow: var(--shadow-xs);
}

.upload-title {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 1.05rem;
  margin-bottom: 6px;
}

.upload-hint {
  font-size: 0.84rem;
  color: var(--text-light);
}

.file-input-hidden {
  display: none;
}

/* Presets de modelos de exemplo */
.sample-models-bar {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--border-subtle);
}

.sample-title {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 12px;
  text-align: center;
}

.sample-buttons-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.sample-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px 8px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  transition: var(--transition-fast);
}
.sample-btn:hover {
  border-color: var(--primary);
  background: var(--primary-light);
}

/* ==========================================================================
   VISUALIZADOR 3D INTERATIVO (THREE.JS)
   ========================================================================== */
.viewer-sticky-card {
  position: sticky;
  top: 90px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.viewer-header {
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-surface-elevated);
}

.viewer-title {
  font-size: 0.9rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.viewer-actions {
  display: flex;
  gap: 6px;
}

.viewer-tool-btn {
  background: transparent;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition-fast);
}
.viewer-tool-btn:hover {
  color: var(--primary);
  border-color: var(--primary);
  background: var(--primary-light);
}
.viewer-tool-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.viewer-canvas-wrap {
  width: 100%;
  height: 340px;
  background: radial-gradient(circle at center, #F8F3EA 0%, #E9DFC9 100%);
  position: relative;
  cursor: grab;
}

.viewer-canvas-wrap:active {
  cursor: grabbing;
}

.viewer-canvas-wrap canvas {
  width: 100% !important;
  height: 100% !important;
  display: block;
}

/* HUD de dimensões sobre o 3D */
.viewer-hud-dimensions {
  position: absolute;
  bottom: 12px;
  left: 12px;
  right: 12px;
  background: rgba(255, 253, 248, 0.88);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.76rem;
  color: var(--text-muted);
}

.hud-item strong {
  color: var(--text-main);
  font-weight: 700;
}

.viewer-empty-state {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px;
  color: var(--text-muted);
  pointer-events: none;
}

/* Resumo de Custos no Viewer */
.viewer-price-summary {
  padding: 18px;
  background: var(--bg-surface-elevated);
  border-top: 1px solid var(--border-subtle);
}

.price-row-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.88rem;
  margin-bottom: 8px;
  color: var(--text-muted);
}

.price-row-item.total {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed var(--border-medium);
  font-size: 1.15rem;
  color: var(--text-main);
  font-weight: 800;
  font-family: var(--font-title);
}

.price-row-item.total .total-amount {
  color: var(--primary);
  font-size: 1.35rem;
}

/* ==========================================================================
   SELETORES DA CALCULADORA (ETAPA 2, 3, 4, 5)
   ========================================================================== */
/* Etapa 2: Escala e Quantidade */
.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 8px;
}

.input-text, .input-select {
  width: 100%;
  height: 46px;
  padding: 10px 16px;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  color: var(--text-main);
  font-family: var(--font-body);
  font-size: 0.95rem;
  transition: var(--transition-fast);
}

.input-text:focus, .input-select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}

.scale-range-control {
  display: flex;
  align-items: center;
  gap: 16px;
}

.scale-range-control input[type="range"] {
  flex: 1;
  accent-color: var(--primary);
  height: 6px;
  cursor: pointer;
}

.scale-value-badge {
  font-family: var(--font-title);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--primary);
  min-width: 55px;
}

/* Quantidade com Botões + e - */
.quantity-stepper {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  background: var(--bg-surface);
  overflow: hidden;
}

.step-count-btn {
  width: 44px;
  height: 44px;
  background: transparent;
  border: none;
  font-size: 1.2rem;
  color: var(--text-main);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
}
.step-count-btn:hover {
  background: var(--bg-surface-alt);
  color: var(--primary);
}

.qty-display-number {
  min-width: 44px;
  text-align: center;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 1.05rem;
}

/* Etapa 3: Materiais e Cores */
.material-cards-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 22px;
}

.material-card-choice {
  background: var(--bg-surface);
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}

.material-card-choice:hover {
  border-color: var(--border-medium);
  background: var(--bg-surface-warm);
}

.material-card-choice.active {
  border-color: var(--primary);
  background: var(--primary-light);
}

.material-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.material-title-choice {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.98rem;
  color: var(--text-main);
}

.material-desc-choice {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Paleta de Cores do Material */
.color-swatches-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.color-swatch-circle {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 2px solid var(--border-medium);
  cursor: pointer;
  position: relative;
  transition: var(--transition-fast);
}

.color-swatch-circle:hover {
  transform: scale(1.15);
}

.color-swatch-circle.active {
  transform: scale(1.15);
  box-shadow: 0 0 0 3px var(--primary);
}

/* Etapa 3.2: Seletor de Qualidade */
.qualities-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 24px;
}

.quality-choice-card {
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 14px 10px;
  text-align: center;
  cursor: pointer;
  background: var(--bg-surface);
  transition: var(--transition);
}

.quality-choice-card:hover {
  border-color: var(--border-medium);
}

.quality-choice-card.active {
  border-color: var(--primary);
  background: var(--primary-light);
}

.quality-layer {
  font-family: var(--font-title);
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--text-main);
  margin-bottom: 2px;
}

.quality-label {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-muted);
}

/* Etapa 4: Preenchimento (Infill) e Acabamentos */
.infill-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 24px;
}

.infill-choice-btn {
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-sm);
  padding: 12px 6px;
  text-align: center;
  background: var(--bg-surface);
  cursor: pointer;
  transition: var(--transition);
}

.infill-choice-btn.active {
  border-color: var(--primary);
  background: var(--primary-light);
  color: var(--primary);
  font-weight: 700;
}

/* Acabamentos Opcionais */
.finishes-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.finish-checkbox-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  cursor: pointer;
  transition: var(--transition-fast);
}

.finish-checkbox-card:hover {
  background: var(--bg-surface-warm);
}

.finish-checkbox-card.active {
  border-color: var(--primary);
  background: var(--primary-light);
}

.finish-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.finish-price-val {
  font-weight: 700;
  color: var(--primary);
  font-family: var(--font-title);
}

/* Ações de Navegação da Calculadora (Voltar / Avançar) */
.wizard-actions-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid var(--border-subtle);
}

/* ==========================================================================
   ABA LOJA DE PROJETOS PRONTOS
   ========================================================================== */
.store-container {
  padding: 40px 0 60px;
}

.store-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 30px;
  flex-wrap: wrap;
}

.store-categories-pills {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.cat-pill {
  padding: 8px 16px;
  border-radius: var(--radius-full);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition-fast);
  min-height: 40px;
}

.cat-pill:hover {
  border-color: var(--border-medium);
  color: var(--text-main);
}

.cat-pill.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.store-search-input {
  max-width: 260px;
  height: 42px;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.product-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
  position: relative;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-medium);
}

.product-image-wrap {
  width: 100%;
  height: 200px;
  background: linear-gradient(180deg, #FAF4EB 0%, #EFE7DB 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.product-badge-float {
  position: absolute;
  top: 12px;
  left: 12px;
}

.product-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-title {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 6px;
  line-height: 1.3;
}

.product-desc {
  font-size: 0.84rem;
  color: var(--text-muted);
  margin-bottom: 14px;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-meta-specs {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.78rem;
  color: var(--text-light);
  margin-bottom: 16px;
}

.product-footer-row {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
}

.product-price-tag {
  font-family: var(--font-title);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--primary);
}

.product-actions-group {
  display: flex;
  gap: 8px;
}

/* ==========================================================================
   ABA CONTATO & FAQ
   ========================================================================== */
.contact-container {
  padding: 40px 0 60px;
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.contact-info-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 32px;
}

.whatsapp-featured-box {
  background: linear-gradient(135deg, #25D366 0%, #1DA851 100%);
  color: white;
  border-radius: var(--radius-md);
  padding: 24px;
  margin-bottom: 28px;
  box-shadow: 0 8px 20px rgba(37, 211, 102, 0.3);
}

.whatsapp-featured-box h4 {
  color: white;
  margin-bottom: 6px;
}

.whatsapp-featured-box p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.9rem;
  margin-bottom: 16px;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  overflow: hidden;
}

.faq-question {
  width: 100%;
  padding: 16px 20px;
  background: transparent;
  border: none;
  font-family: var(--font-title);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
  text-align: left;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
}

.faq-answer {
  padding: 0 20px 16px;
  font-size: 0.9rem;
  color: var(--text-muted);
  display: none;
  line-height: 1.6;
}

.faq-item.open .faq-answer {
  display: block;
}

/* ==========================================================================
   ABA MINHA CONTA / PAINEL ADMINISTRATIVO
   ========================================================================== */
.account-container {
  padding: 40px 0 60px;
}

.auth-card-centered {
  max-width: 440px;
  margin: 0 auto;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: var(--shadow-md);
  text-align: center;
}

.auth-header h3 {
  margin-bottom: 8px;
}

.auth-header p {
  margin-bottom: 24px;
  font-size: 0.92rem;
}

/* Botão Google Customizado */
.google-login-custom-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: #FFFFFF;
  border: 1px solid var(--border-medium);
  padding: 12px 18px;
  border-radius: var(--radius-full);
  font-family: var(--font-title);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  transition: var(--transition-fast);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.google-login-custom-btn:hover {
  background: #FDFDFD;
  border-color: #BBB;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.auth-divider {
  display: flex;
  align-items: center;
  margin: 24px 0;
  color: var(--text-light);
  font-size: 0.8rem;
  text-transform: uppercase;
}
.auth-divider::before, .auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border-subtle);
}
.auth-divider span {
  padding: 0 12px;
}

/* Painel de Administração Integrado */
.admin-dashboard-wrap {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.admin-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 28px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  flex-wrap: wrap;
  gap: 14px;
}

.admin-user-info {
  display: flex;
  align-items: center;
  gap: 14px;
}

.admin-subtabs-nav {
  display: flex;
  gap: 8px;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 12px;
  overflow-x: auto;
}

.admin-subtab-btn {
  padding: 8px 16px;
  border-radius: var(--radius-full);
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-muted);
  font-family: var(--font-title);
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  white-space: nowrap;
}

.admin-subtab-btn.active {
  background: var(--primary-light);
  color: var(--primary);
  border-color: var(--primary-light-border);
}

.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.admin-stat-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px;
}

.stat-num {
  font-family: var(--font-title);
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-main);
  margin-top: 6px;
}

/* Tabela Limpa */
.custom-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

.custom-table th {
  padding: 12px 16px;
  background: var(--bg-surface-alt);
  color: var(--text-muted);
  font-weight: 600;
  border-bottom: 1px solid var(--border-subtle);
}

.custom-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-subtle);
}

/* Responsividade específica de componentes */
@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .calc-layout {
    grid-template-columns: 1fr;
  }

  .viewer-sticky-card {
    position: relative;
    top: 0;
    order: -1; /* No mobile o 3D fica logo acima para feedback imediato */
    margin-bottom: 24px;
  }

  .steps-grid {
    grid-template-columns: 1fr;
  }

  .contact-layout {
    grid-template-columns: 1fr;
  }

  .admin-stats-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 600px) {
  .wizard-progress-bar {
    overflow-x: auto;
    padding-bottom: 8px;
  }

  .material-cards-grid {
    grid-template-columns: 1fr;
  }

  .qualities-grid {
    grid-template-columns: 1fr;
  }

  .infill-grid {
    grid-template-columns: 1fr 1fr;
  }

  .admin-stats-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   SISTEMA DE AVALIAÇÕES E DEPOIMENTOS COM FOTOS (CREME SUAVE)
   ========================================================================== */
.reviews-hero-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  gap: 24px;
  flex-wrap: wrap;
  box-shadow: var(--shadow-sm);
}

.reviews-score-col {
  display: flex;
  align-items: center;
  gap: 20px;
}

.reviews-rating-number {
  font-family: var(--font-title);
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1;
  color: var(--text-main);
}

.reviews-score-stars {
  color: #E8A838;
  font-size: 1.4rem;
  letter-spacing: 2px;
  margin-bottom: 4px;
}

.reviews-filter-bar {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  overflow-x: auto;
  padding-bottom: 6px;
}

.reviews-filter-btn {
  padding: 8px 18px;
  border-radius: var(--radius-full);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition-fast);
}

.reviews-filter-btn:hover {
  background: var(--bg-surface-elevated);
  border-color: var(--border-medium);
}

.reviews-filter-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 22px;
  margin-bottom: 48px;
}

.review-card {
  padding: 24px;
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-md);
  transition: var(--transition);
}

.review-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.review-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.review-user-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.review-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--primary-light);
  color: var(--primary);
  font-weight: 700;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.review-author-name {
  font-size: 1rem;
  margin-bottom: 2px;
}

.review-author-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.review-badge-verified {
  font-size: 0.72rem;
  font-weight: 700;
  color: #2E7D32;
  background: #E8F5E9;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.review-rating-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 14px;
}

.review-stars-gold {
  color: #E8A838;
  font-size: 1.15rem;
  letter-spacing: 2px;
}

.review-project-tag {
  font-size: 0.76rem;
  background: var(--bg-surface-alt);
  color: var(--text-main);
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 600;
  max-width: 160px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.review-card-media {
  position: relative;
  width: 100%;
  height: 200px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin-bottom: 14px;
  cursor: pointer;
  background: #EAE5D9;
}

.review-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.review-card-media:hover img {
  transform: scale(1.04);
}

.photo-zoom-badge {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(0, 0, 0, 0.65);
  color: white;
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  backdrop-filter: blur(4px);
  pointer-events: none;
}

.review-comment-body {
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text-main);
  margin-bottom: 16px;
  flex: 1;
}

.review-footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border-subtle);
  padding-top: 12px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.review-material-badge {
  font-weight: 600;
  color: var(--primary);
}

.review-admin-bar {
  display: flex;
  gap: 6px;
}

/* Modal de Avaliação */
.review-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(40, 32, 22, 0.65);
  backdrop-filter: blur(5px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.review-modal-card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  padding: 32px;
  max-width: 540px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 16px 40px rgba(0,0,0,0.2);
  position: relative;
}

.star-rating-picker {
  display: flex;
  gap: 8px;
  margin: 10px 0 6px;
}

.star-select-btn {
  background: none;
  border: none;
  font-size: 1.8rem;
  color: #D3C9BD;
  cursor: pointer;
  transition: transform 0.15s ease, color 0.15s ease;
  padding: 0 2px;
}

.star-select-btn:hover,
.star-select-btn.active {
  color: #E8A838;
  transform: scale(1.15);
}

.photo-preview-box {
  position: relative;
  width: 110px;
  height: 110px;
  border-radius: 8px;
  overflow: hidden;
  margin-top: 8px;
  border: 2px solid var(--primary-light-border);
}

.photo-preview-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.btn-remove-photo {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 24px;
  height: 24px;
  background: rgba(0,0,0,0.7);
  color: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

/* Lightbox de Foto Ampliada */
.lightbox-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.88);
  backdrop-filter: blur(8px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  cursor: pointer;
}

.lightbox-modal img {
  max-width: 90vw;
  max-height: 85vh;
  border-radius: 10px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.5);
  object-fit: contain;
}

