/* propostaexterna.css */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f3f4f6;
  color: #111827;
}

html, body { overflow-y: auto; }
.px-page {
  min-height: 100vh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 24px 16px;
}

.px-card {
  width: 100%;
  max-width: 720px;
  background: #ffffff;
  border-radius: 16px;
  padding: 24px 24px 28px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.12);
}

/* CABEÇALHO COM LOGO DO PARCEIRO */
.px-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 12px;
}

.px-partner-logo {
  max-height: 48px;
  max-width: 160px;
  object-fit: contain;
}

.px-header-text {
  flex: 1;
}

.px-card h1 {
  margin: 0 0 4px;
  font-size: 22px;
  font-weight: 700;
  color: #7a1919;
}

.px-subtitle {
  margin: 0;
  font-size: 14px;
  color: #6b7280;
}

.px-section {
  border-top: 1px solid #e5e7eb;
  padding-top: 16px;
  margin-top: 16px;
}

.px-section h2 {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 600;
  color: #7a1919;
}

.px-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px 16px;
}

.px-colspan-2 { grid-column: span 2; }

.px-input {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.px-input label {
  font-size: 13px;
  font-weight: 500;
  color: #374151;
}

.px-input input,
.px-input select {
  border-radius: 10px;
  border: 1px solid #d1d5db;
  padding: 8px 10px;
  font-size: 14px;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.px-input input:focus,
.px-input select:focus {
  border-color: #b91c1c;
  box-shadow: 0 0 0 1px rgba(185, 28, 28, 0.25);
}

/* CAMPOS MENORES (CPF/CNPJ E CELULAR) */
.px-input--small {
  max-width: 280px;
}

.px-input--small input {
  max-width: 100%;
}

.px-help {
  font-size: 11px;
  color: #6b7280;
}

.px-actions {
  margin-top: 20px;
  display: flex;
  justify-content: flex-end;
}

.px-btn-primary {
  border: none;
  border-radius: 999px;
  padding: 10px 22px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  background: linear-gradient(135deg, #7a1919, #b91c1c);
  color: #ffffff;
  box-shadow: 0 8px 16px rgba(185, 28, 28, 0.3);
  transition: transform 0.1s, box-shadow 0.1s, filter 0.1s;
}

.px-btn-primary:hover {
  filter: brightness(1.05);
  box-shadow: 0 10px 20px rgba(185, 28, 28, 0.4);
  transform: translateY(-1px);
}

.px-btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 4px 10px rgba(185, 28, 28, 0.35);
}

/* Seção "desabilitada" visualmente */
.px-section[data-disabled="true"] {
  opacity: 0.45;
  pointer-events: none;
}

.px-input-disabled {
  background-color: #f3f4f6;
  color: #9ca3af;
  cursor: not-allowed;
}

/* TELA FINAL DE SUCESSO */
.px-success {
  margin-top: 8px;
  padding: 32px 24px;
  border-radius: 0.75rem;
  border: 1px solid #bbf7d0;
  background-color: #ecfdf3;
  text-align: center;
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.12);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.px-success-icon {
  width: 56px;
  height: 56px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  font-weight: 700;
  background-color: #22c55e;
  color: #f0fdf4;
  box-shadow: 0 0 0 8px rgba(34, 197, 94, 0.15);
  margin-bottom: 4px;
}

.px-success h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: #166534;
}

.px-success-message {
  margin: 0;
  font-size: 14px;
  color: #14532d;
  max-width: 480px;
}

/* Estilos para a página de sócio */
#pxSocioContent .px-success-icon {
  font-size: 48px;
  margin-bottom: 16px;
  background-color: #7a1919;
}

#pxSocioContent .px-success h2 {
  color: #7a1919;
}

.px-btn-secondary {
  border: 1px solid #d1d5db;
  border-radius: 999px;
  padding: 10px 22px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  background: #ffffff;
  color: #374151;
  margin-right: 12px;
  transition: background-color 0.15s;
}

.px-btn-secondary:hover {
  background-color: #f9fafb;
}

/* Ajuste para campos desabilitados na seção de sócio */
#pxSocioContent .px-input input:disabled {
  background-color: #f3f4f6;
  color: #6b7280;
  cursor: not-allowed;
}

#pxSocioContent .px-input input:disabled:focus {
  border-color: #d1d5db;
  box-shadow: none;
}

/* RODAPÉ COM LOGO TJP E AVISOS */
.px-footer {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid #e5e7eb;
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.px-footer-logo-box {
  flex-shrink: 0;
}

.px-tjp-logo {
  max-height: 40px;
  max-width: 140px;
  object-fit: contain;
}

.px-footer-texts {
  font-size: 11px;
  color: #4b5563;
  line-height: 1.4;
}

.px-footer-texts p {
  margin: 0 0 6px;
}

/* Responsivo */
@media (max-width: 900px) {
  .px-grid {
    grid-template-columns: 1fr;
  }

  .px-card {
    padding: 20px 16px 22px;
  }

  .px-footer {
    flex-direction: column;
  }

  .px-input--small {
    max-width: 100%;
  }
}

/* Lista de sócios já cadastrados */
.px-socios-list {
  margin: 10px 0 0 18px;
  padding: 0;
}
.px-socios-list li {
  margin: 6px 0;
}

/* Ações com botões nas duas pontas */
.px-actions--between{justify-content:space-between;}

/* MODAL: aviso de horário de atendimento */
.px-modal-overlay{
  position: fixed;
  inset: 0;
  background: rgba(17, 24, 39, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 9999;
}

.px-modal-card{
  max-width: 720px;
}

.px-modal-header{
  margin-bottom: 10px;
}

.px-modal-title{
  margin: 0 0 4px;
  font-size: 18px;
  font-weight: 700;
  color: #7a1919;
}

.px-modal-subtitle{
  margin: 0;
  font-size: 13px;
  color: #6b7280;
}

.px-modal-body{
  border-top: 1px solid #e5e7eb;
  padding-top: 12px;
}

.px-modal-list{
  margin: 0 0 12px 18px;
  padding: 0;
  line-height: 1.55;
  font-size: 14px;
  color: #111827;
}

.px-modal-note{
  margin: 0 0 14px;
  font-size: 13px;
  color: #374151;
}

/* ====== DADOSCOMPLEMENTARES (CNPJ) - estilos replicados ====== */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f3f4f6;
  color: #111827;
  min-height: 100vh;
  width: 100%;
  overflow-x: hidden;
  font-size: 13px;
}

.dc-page {
  max-width: 900px;
  margin: 0 auto;
  padding: 16px;
  width: 100%;
}

.dc-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 4px 20px rgba(15, 23, 42, 0.08);
  border: 1px solid #e5e7eb;
  width: 100%;
  overflow: hidden;
}

.px-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
}

.px-partner-logo {
  max-height: 48px;
  max-width: 160px;
  object-fit: contain;
}

.px-header-text {
  flex: 1;
}

.px-title {
  margin: 0 0 4px;
  font-size: 20px;
  font-weight: 700;
  color: #7a1919;
}

.px-subtitle {
  margin: 0;
  font-size: 13px;
  color: #4b5563;
}

/* Resumo do cliente */
.dc-resumo, .px-resumo, #pxResumoCliente {
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  border: 2px solid #fca5a5;
  border-radius: 10px;
  padding: 12px;
  margin: 16px 0;
  font-size: 13px;
  color: #7c2d12;
  font-weight: 500;
  box-shadow: 0 2px 8px rgba(185, 28, 28, 0.1);
  width: 100%;
  overflow: hidden;
}
.dc-resumo-grid, .px-resumo-grid, #pxResumoCliente .px-resumo-grid, #pxResumoCliente .dc-resumo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  width: 100%;
}
.dc-resumo strong, .px-resumo strong, #pxResumoCliente strong {
  color: #b91c1c;
  font-weight: 600;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: block;
  margin-bottom: 4px;
}
.dc-resumo span, .px-resumo span, #pxResumoCliente span {
  color: #1f2937;
  font-weight: 600;
  font-size: 12px;
  display: block;
}

/* Steps */
.dc-step {
  background: #ffffff;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 16px;
  border: 1px solid #e5e7eb;
  width: 100%;
  display: none;
}

.dc-step-ativa {
  display: block;
  animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.dc-step h2 {
  margin: 0 0 20px;
  font-size: 15px;
  font-weight: 700;
  color: #7a1919;
  border-bottom: 2px solid #f3f4f6;
  padding-bottom: 10px;
}

/* Grid de campos */
.dc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 12px;
  width: 100%;
}

.dc-field {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.dc-field-full {
  grid-column: 1 / -1;
}

.dc-span-2 { grid-column: span 2; }

.dc-field label {
  font-size: 11px;
  font-weight: 600;
  margin-bottom: 6px;
  color: #374151;
}

.dc-field input,
.dc-field select {
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid #d1d5db;
  font-size: 13px;
  background: #fff;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  width: 100%;
  max-width: 100%;
}

.dc-field input:focus,
.dc-field select:focus {
  border-color: #b91c1c;
  box-shadow: 0 0 0 3px rgba(185, 28, 28, 0.1);
}

/* Campos específicos */
.dc-renda {
  text-align: right;
}

/* Ações */
.dc-actions {
  margin-top: 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: flex-end;
}

.dc-btn-primary,
.dc-btn-secondary {
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  min-width: 120px;
  transition: all 0.2s ease;
}

.dc-btn-primary {
  background: linear-gradient(135deg, #7a1919, #b91c1c);
  color: #fff;
  border: none;
}

.dc-btn-primary:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(185, 28, 28, 0.3);
}

.dc-btn-primary:disabled {
  background: #9ca3af;
  cursor: not-allowed;
}

.dc-btn-secondary {
  background: #e5e7eb;
  color: #111827;
  border: none;
}

.dc-btn-secondary:hover {
  background: #d1d5db;
}

/* Mensagens */
.dc-msg {
  margin-top: 10px;
  font-size: 12px;
  padding: 8px 12px;
  border-radius: 6px;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
}

/* Bloco interno de step */
.dc-step-block {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px dashed #e5e7eb;
}

/* Estado desabilitado */
.dc-disabled input,
.dc-disabled select,
.dc-disabled button {
  opacity: 0.6;
  pointer-events: none;
}

/* Tela de sucesso final */
.dc-success {
  text-align: center;
  padding: 50px 20px;
  background: #f0fdf4;
  border-radius: 16px;
  border: 2px solid #bbf7d0;
  margin: 20px 0;
}

.dc-success-icon {
  font-size: 60px;
  color: #16a34a;
  margin-bottom: 20px;
}

.dc-success h2 {
  color: #16a34a;
  font-size: 24px;
  margin-bottom: 12px;
}

.dc-success-message {
  font-size: 16px;
  color: #374151;
}

/* Bloco de documentos (Step 4) */
.cl-docs {
  margin-top: 16px;
  border-top: 1px dashed #e5e7eb;
  padding-top: 16px;
}

.cl-docs h2 {
  font-size: 14px;
  margin: 12px 0 8px;
  color: #7a1919;
}

.cl-docs-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.doc-row {
  display: grid;
  grid-template-columns: 2fr 2fr 2fr;
  align-items: center;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
  background: #f9fafb;
  font-size: 12px;
}

.doc-label {
  font-weight: 600;
  color: #374151;
}

.doc-status {
  color: #4b5563;
}

.doc-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

/* Botões dos documentos */
.cl-btn {
  padding: 8px 12px;
  border-radius: 6px;
  border: none;
  background: #e5e7eb;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cl-btn:hover {
  background: #d1d5db;
}

/* Responsivo para linhas de documento */
@media (max-width: 768px) {
  .doc-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .doc-actions {
    justify-content: flex-start;
  }
}

/* Rodapé */
.px-footer {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid #e5e7eb;
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.px-footer-logo-box {
  flex-shrink: 0;
}

.px-tjp-logo {
  max-height: 40px;
  max-width: 140px;
  object-fit: contain;
}

.px-footer-texts {
  font-size: 11px;
  color: #4b5563;
  line-height: 1.4;
}

.px-footer-texts p {
  margin: 0 0 6px;
}

.px-footer-text {
  margin: 0;
  line-height: 1.4;
}

/* Responsividade geral */
@media (max-width: 768px) {
  .dc-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .dc-btn-primary,
  .dc-btn-secondary {
    min-width: 110px;
    font-size: 12px;
  }
}

@media (max-width: 576px) {
  .dc-grid {
    grid-template-columns: 1fr;
  }

  .dc-actions {
    flex-direction: column;
  }

  .dc-btn-primary,
  .dc-btn-secondary {
    width: 100%;
  }

  .dc-step h2 {
    font-size: 14px;
  }

  .px-header {
    flex-direction: column;
    align-items: flex-start;
  }

  /* FIX: evitar colunas implícitas (span 2) no celular */
  .dc-grid > *{
    grid-column: 1 / -1 !important;
    min-width: 0 !important;
  }
  .dc-span-2,
  .dc-field-full{
    grid-column: 1 / -1 !important;
  }

}

/* Link de download do documento */
.dc-doc-link {
  text-decoration: underline;
}

/* STEP 10 (CNPJ) - Documentos */
.dc-docs {
  margin-top: 16px;
  border-top: 1px dashed #e5e7eb;
  padding-top: 16px;
}

.dc-doc-row {
  display: grid;
  grid-template-columns: 2fr 2fr 2fr;
  align-items: center;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
  background: #f9fafb;
  font-size: 12px;
}

.dc-doc-label {
  font-weight: 600;
  color: #374151;
}

.dc-doc-status {
  color: #4b5563;
}

.dc-doc-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
  align-items: center;
}

.dc-docs .dc-btn {
  padding: 8px 12px;
  border-radius: 6px;
  border: none;
  background: #e5e7eb;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.dc-docs .dc-btn:hover {
  background: #d1d5db;
}

.dc-docs .dc-btn-secondary {
  background: #e5e7eb;
  color: #111827;
}

.dc-docs .dc-btn-secondary:hover {
  background: #d1d5db;
}

@media (max-width: 768px) {
  .dc-doc-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .dc-doc-actions {
    justify-content: flex-start;
  }
}

/* Step 11: Opções Comerciais */
.dc-step-help{
  margin: -4px 0 10px 0;
  color: #4b5563;
}

.dc-opcoes{
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 10px 0 14px 0;
}

.dc-opcao{
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  align-items: start;
  padding: 10px 12px;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
}

.dc-opcao:hover{
  border-color: #d1d5db;
}

.dc-opcao.dc-opcao-selected{
  background: #d7f5d7;
  border-color: #86efac;
}

.dc-opcao input[type="radio"]{
  margin-top: 2px;
}

.dc-opcao-tit{
  font-weight: 700;
  color: #111827;
  margin-bottom: 6px;
}

.dc-opcao-grid{
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 8px 12px;
}

.dc-opcao-item{
  font-size: 12px;
  color: #374151;
}

.dc-opcao-item b{
  color: #111827;
  font-weight: 600;
}

.dc-opcao-aceita{
  margin-top: 6px;
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  color: #065f46;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  padding: 4px 8px;
  border-radius: 999px;
}

@media (max-width: 780px){
  .dc-opcao-grid{
    grid-template-columns: repeat(2, minmax(120px, 1fr));
  }
}

/* Proposta externa: pergunta "doc do veículo em seu nome?" + canal proposta */
.px-box--compact{
  padding: 12px 14px;
  margin-top: 10px;
}
.px-radio-row{
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 6px;
}
.px-radio{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}
.px-radio input{
  cursor: pointer;
}
.px-input--inline{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.px-label-inline{
  margin: 0;
  flex: 1 1 auto;
}

/* Controles com borda */
.px-control-box{
  border: 1px solid rgba(0,0,0,0.18);
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
}

.px-select-control{
  width: 100%;
  border: 1px solid rgba(0,0,0,0.18);
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
  outline: none;
  font: inherit;
}

.px-select-control:focus{
  border-color: rgba(0,0,0,0.35);
}

/* Correção: boxes com borda igual aos inputs */
.px-box{
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #fff;
  padding: 12px;
}
.px-box--compact{ padding: 12px; }
.px-radio-row{
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 10px 14px;
}
.px-input--inline{
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Correção: garantir que botão/rodapé sempre apareçam */
.px-actions{ margin-top: 20px; display:flex; gap: 12px; }
.px-footer{ margin-top: 18px; }

/* =========================================================
   SOLUÇÃO SIMPLIFICADA: RESET COMPLETO DAS SEÇÕES CPF
   ========================================================= */

/* REMOVER COMPLETAMENTE A SEPARAÇÃO ENTRE AS DUAS SEÇÕES */
/* Quando o CPF está desabilitado (após validação) */
#pxDoc:disabled ~ #pxIdentificacaoSection,
#pxDoc:disabled ~ #pxPessoaSection {
  border-top: none !important;
  padding-top: 0 !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  display: block !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

/* Esconder os títulos das seções quando em modo resumo */
#pxDoc:disabled ~ #pxIdentificacaoSection > h2,
#pxDoc:disabled ~ #pxPessoaSection > h2 {
  display: none !important;
}

/* CRIAR UM ÚNICO CONTAINER COM AS DUAS SEÇÕES JUNTAS */
#pxDoc:disabled ~ #pxIdentificacaoSection,
#pxDoc:disabled ~ #pxPessoaSection {
  background: linear-gradient(135deg, #fef2f2, #fee2e2) !important;
  border: 2px solid #fca5a5 !important;
  border-radius: 10px !important;
  padding: 12px !important;
  margin: 16px 0 !important;
  font-size: 13px !important;
  color: #7c2d12 !important;
  font-weight: 500 !important;
  box-shadow: 0 2px 8px rgba(185, 28, 28, 0.1) !important;
  width: 100% !important;
  overflow: hidden !important;
}

/* Primeira seção (CPF) - sem margem inferior */
#pxDoc:disabled ~ #pxIdentificacaoSection {
  margin-bottom: 0 !important;
  border-bottom: none !important;
  border-bottom-left-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
}

/* Segunda seção (Nome) - sem margem superior e juntar com a anterior */
#pxDoc:disabled ~ #pxPessoaSection {
  margin-top: 0 !important;
  border-top: none !important;
  border-top-left-radius: 0 !important;
  border-top-right-radius: 0 !important;
  padding-top: 0 !important;
}

/* Reconfigurar o grid interno para ter 2 colunas (CPF e Nome lado a lado) */
#pxDoc:disabled ~ #pxIdentificacaoSection .px-grid,
#pxDoc:disabled ~ #pxPessoaSection .px-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)) !important;
  gap: 12px !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

/* Estilo dos labels (igual ao CNPJ) */
#pxDoc:disabled ~ #pxIdentificacaoSection .px-input label,
#pxDoc:disabled ~ #pxPessoaSection .px-input label {
  color: #b91c1c !important;
  font-weight: 600 !important;
  font-size: 11px !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px !important;
  display: block !important;
  margin: 0 0 4px 0 !important;
}

/* Estilo dos campos desabilitados (apenas texto) */
#pxDoc:disabled ~ #pxIdentificacaoSection .px-input input:disabled,
#pxDoc:disabled ~ #pxPessoaSection .px-input input:disabled {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
  margin: 0 !important;
  height: auto !important;
  min-height: unset !important;
  color: #1f2937 !important;
  font-weight: 600 !important;
  font-size: 12px !important;
  opacity: 1 !important;
  -webkit-text-fill-color: #1f2937 !important;
  cursor: default !important;
  width: 100% !important;
  line-height: 1.4 !important;
}

/* Esconder os campos extras (Data Nascimento e Celular) */
#pxDoc:disabled ~ #pxPessoaSection .px-input:has(#pxDataNasc),
#pxDoc:disabled ~ #pxPessoaSection .px-input:has(#pxCelular) {
  display: none !important;
}

/* Responsivo: quando a tela for pequena, 1 coluna */
@media (max-width: 768px) {
  #pxDoc:disabled ~ #pxIdentificacaoSection .px-grid,
  #pxDoc:disabled ~ #pxPessoaSection .px-grid {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
}

/* =========================================================
   ESTILO CNPJ (MANTIDO COMO REFERÊNCIA)
   ========================================================= */
#pxSocioIdentSection {
  background: linear-gradient(135deg, #fef2f2, #fee2e2) !important;
  border: 2px solid #fca5a5 !important;
  border-radius: 10px !important;
  padding: 12px !important;
  margin: 16px 0 !important;
  font-size: 13px !important;
  color: #7c2d12 !important;
  font-weight: 500 !important;
  box-shadow: 0 2px 8px rgba(185, 28, 28, 0.1) !important;
  width: 100% !important;
  overflow: hidden !important;
}

#pxSocioIdentSection > h2 {
  display: none !important;
}

#pxSocioIdentSection .px-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)) !important;
  gap: 12px !important;
  width: 100% !important;
  margin: 0 !important;
}

#pxSocioIdentSection .px-input {
  margin: 0 !important;
}

#pxSocioIdentSection .px-input label {
  color: #b91c1c !important;
  font-weight: 600 !important;
  font-size: 11px !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px !important;
  display: block !important;
  margin: 0 0 4px 0 !important;
}

#pxSocioIdentSection .px-input input:disabled {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
  margin: 0 !important;
  height: auto !important;
  color: #1f2937 !important;
  font-weight: 600 !important;
  font-size: 12px !important;
  opacity: 1 !important;
  -webkit-text-fill-color: #1f2937 !important;
  cursor: default !important;
}


/* =========================================================
   FIX RESPONSIVIDADE CPF/CNPJ NO CELULAR
   - No CPF, vários campos usam grid-column (span 2/3). No mobile isso cria colunas implícitas.
   - Forçamos 1 coluna e itens ocupando a linha inteira (igual ao padrão do CNPJ).
   ========================================================= */
@media (max-width: 768px){
  /* Qualquer grid da jornada CPF (px-grid) vira 1 coluna */
  .px-grid{
    grid-template-columns: 1fr !important;
  }
  .px-grid > *{
    grid-column: 1 / -1 !important;
    min-width: 0 !important;
    width: 100% !important;
  }
  .px-colspan-2,
  .px-fullrow{
    grid-column: 1 / -1 !important;
  }
}

/* BANNER MODAL */
.px-banner-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 90%;
  max-height: 90%;
  position: relative;
}

.px-banner-card img {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

#pxBannerClose {
  margin-top: 12px;
  padding: 10px 24px;
  background: #fff;
  color: #333;
  border: none;
  border-radius: 50px;
  font-weight: 700;
  cursor: not-allowed;
  opacity: 0.7;
  transition: all 0.2s;
}

#pxBannerClose:not(:disabled) {
  cursor: pointer;
  opacity: 1;
  background: #7a1919;
  color: #fff;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}
