.visitor-dialog {
  border: 1px solid var(--line);
  border-radius: 12px;
  width: min(420px, calc(100% - 32px));
  max-height: calc(100dvh - 32px);
  overflow: auto;
  padding: 24px;
  color: var(--ink);
  background: var(--surface);
  font-family: var(--sans, system-ui);
}
.visitor-dialog::backdrop {
  background: rgb(0 0 0 / 0.6);
}
.visitor-dialog h2 {
  font-size: 22px;
  margin: 0 0 12px;
}
.visitor-dialog p {
  line-height: 1.5;
}
.visitor-dialog label {
  display: block;
  font-weight: 600;
  margin: 14px 0 6px;
}
.visitor-dialog input {
  box-sizing: border-box;
  width: 100%;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  background: var(--surface);
  font: inherit;
}
.visitor-dialog input[aria-invalid="true"] {
  border-color: var(--public-brand);
}
.visitor-dialog .visitor-note {
  font-size: 12px;
  color: var(--muted);
}
.visitor-actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}
.visitor-actions button {
  border: 1px solid var(--public-brand);
  border-radius: 6px;
  padding: 10px 16px;
  background: var(--public-brand);
  color: var(--surface);
  cursor: pointer;
  font: inherit;
}
.visitor-actions [data-cancel] {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.visitor-error {
  color: var(--public-brand);
}
.visitor-bar {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 8px 24px;
  font: 13px var(--sans, system-ui);
  color: var(--muted);
}
.visitor-bar button {
  border: 0;
  background: transparent;
  color: inherit;
  padding: 4px;
  cursor: pointer;
  text-decoration: underline;
  font: inherit;
}
.visitor-bar span {
  font-weight: 600;
}
.quote-site .visitor-bar,
.quote-integrated .visitor-bar {
  position: relative;
  z-index: 2;
}

.visitor-dialog [hidden] {
  display: none !important;
}
.visitor-dialog .visitor-remember {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
}
.visitor-remember input[type="checkbox"] {
  width: 18px;
  height: 18px;
  flex: none;
}
.sf-bottom [data-visitor-privacy] {
  background: none;
  border: 0;
  padding: 0;
  color: inherit;
  font: inherit;
  text-decoration: underline;
  cursor: pointer;
}

html body .visitor-dialog {
  width: min(420px, calc(100% - 32px));
  box-sizing: border-box;
  padding: 28px;
}
html body .visitor-dialog #visitor-title {
  text-align: center;
  font-size: clamp(23px, 5vw, 28px);
  line-height: 1.2;
  margin: 0 0 22px;
}
.visitor-dialog .visitor-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  margin: -1px;
  padding: 0;
  white-space: nowrap;
}
html body .visitor-dialog .visitor-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
}
html body .visitor-dialog .visitor-actions button {
  height: 46px;
  padding: 10px 16px;
  text-align: center;
}
html body .visitor-dialog .visitor-actions [data-back] {
  background: var(--paper, #f7f6f5);
  border-color: var(--line, #ddd);
  color: var(--ink, #111);
  grid-row: 1;
  grid-column: 1;
}
html body .visitor-dialog .visitor-actions:has([data-back]:not([hidden])) [type="submit"] {
  grid-column: 2;
}
html body .visitor-dialog .visitor-note {
  font-size: 12px;
  margin: 10px 0;
}
.visitor-dialog .visitor-error:empty {
  display: none;
}
.visitor-privacy-link {
  border: 0;
  background: none;
  padding: 0;
  color: inherit;
  text-decoration: underline;
  cursor: pointer;
  font: inherit;
}
html body #app .visitor-bar {
  padding: 0 0 14px;
  margin: 0 0 20px;
  border-bottom: 1px solid var(--line, #ddd);
  max-width: none;
  gap: 10px;
  justify-content: flex-end;
}
html body .visitor-bar button {
  font-size: 12px;
  border: 1px solid var(--line, #ddd);
  border-radius: 6px;
  padding: 6px 10px;
  text-decoration: none;
  line-height: 1.2;
}
html body .visitor-bar span {
  font-size: 13px;
  font-weight: 500;
}
@media (max-width: 450px) {
  html body .visitor-dialog {
    padding: 24px 20px;
  }
  html body #app .visitor-bar {
    justify-content: space-between;
  }
}

/* Identificação discreta no cabeçalho, sem faixa adicional. */
.visitor-profile {
  position: relative;
  flex: none;
  margin: 0;
  color: inherit;
}
.visitor-profile > summary {
  list-style: none;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid currentColor;
  cursor: pointer;
  opacity: 0.85;
}
.visitor-profile > summary::-webkit-details-marker {
  display: none;
}
.visitor-profile > summary:hover,
.visitor-profile[open] > summary {
  opacity: 1;
  background: rgb(127 127 127 / 0.14);
}
.visitor-profile > summary svg {
  width: 20px;
  height: 20px;
}
html body .visitor-profile-panel {
  position: absolute;
  z-index: 200;
  right: 0;
  top: calc(100% + 12px);
  width: 260px;
  max-width: calc(100vw - 32px);
  box-sizing: border-box;
  display: grid;
  gap: 8px;
  padding: 20px;
  background: var(--site-superficie, var(--surface, #fff));
  color: var(--site-texto, var(--ink, #111));
  border: 1px solid var(--line, #ddd);
  border-radius: 10px;
  box-shadow: 0 10px 30px rgb(0 0 0 / 0.15);
  font: 14px var(--sans, system-ui);
  text-align: left;
}
.visitor-profile-panel strong {
  font-size: 16px;
  margin-bottom: 5px;
}
.visitor-profile-panel span {
  overflow-wrap: anywhere;
  font-size: 14px;
}
html body .visitor-profile-panel button {
  font: inherit;
  color: inherit;
  background: transparent;
  border: 1px solid var(--line, #ddd);
  border-radius: 6px;
  padding: 9px 12px;
  cursor: pointer;
  margin: 8px 0 0;
  text-align: center;
  min-height: 40px;
}
html body .visitor-profile-panel button:last-child {
  margin: 0;
  border-color: transparent;
  font-size: 12px;
  color: var(--site-secundario, var(--muted, #555));
}
.visitor-profile:not([open]) > .visitor-profile-panel {
  display: none !important;
}
.visitor-profile > summary:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 4px;
}
#app > .visitor-profile {
  float: right;
  margin-bottom: 12px;
}
@media (max-width: 480px) {
  .visitor-profile > summary {
    width: 34px;
    height: 34px;
  }
  .visitor-profile-panel {
    right: 0;
  }
}

/* Menu compacto, com área de toque sem contorno ao redor da pessoa. */
html body .visitor-profile > summary {
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 6px;
}
html body .visitor-profile-panel {
  padding: 16px;
  gap: 6px;
  width: 252px;
}
html body .visitor-profile-panel strong {
  margin-bottom: 2px;
}
html body .visitor-profile-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 8px;
}
html body .visitor-profile-actions button {
  margin: 0;
  min-height: 40px;
  border: 1px solid var(--line);
  font-size: 14px;
  color: inherit;
}
html body .visitor-profile-panel > .visitor-privacy-link.visitor-privacy-link {
  min-height: 36px;
  padding: 6px 0;
  margin: 0;
  border: 0;
  text-align: left;
  text-decoration: underline;
  font-size: 12px;
}
html body .visitor-dialog .visitor-actions {
  grid-template-columns: repeat(auto-fit, minmax(min(115px, 100%), 1fr));
}
html body .visitor-dialog .visitor-actions button {
  min-width: 0;
  height: auto;
  min-height: 46px;
}
html body .visitor-dialog [data-close] {
  color: var(--ink);
  background: var(--surface);
  border-color: var(--line);
}

html body .visitor-profile-panel .visitor-profile-actions button {
  font-size: 14px;
  min-height: 40px;
  border: 1px solid var(--line);
  color: inherit;
  margin: 0;
}

/* Meus dados (28/10/2026): ícone no mesmo padrão do botão de orçamento; painel alinhado ao ícone,
   baixo e largo, nome e telefone na mesma linha, ações pequenas e privacidade discreta. */
html body .site-header-actions {
  gap: 8px;
}
html body .visitor-profile {
  position: relative;
}
html body .visitor-profile > summary {
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 7px;
  background: color-mix(in srgb, currentColor 12%, transparent);
  opacity: 1;
}
html body .visitor-profile > summary:hover,
html body .visitor-profile[open] > summary {
  background: color-mix(in srgb, currentColor 22%, transparent);
}
html body .visitor-profile-panel {
  width: 280px;
  max-width: calc(100vw - 24px);
  padding: 12px 16px 10px;
  gap: 0;
  justify-items: center;
  text-align: center;
}
html body .visitor-profile-panel > strong {
  justify-self: stretch;
  margin: 0 0 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line, #ddd);
  font-size: 14px;
}
html body .visitor-profile-panel .visitor-profile-data {
  display: grid;
  justify-items: start;
  justify-self: stretch;
  gap: 4px;
  width: 100%;
  margin: 0;
}
html body .visitor-profile-panel .visitor-profile-row {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0;
  font-size: 14px;
  line-height: 1.4;
  white-space: nowrap;
  max-width: 100%;
}
html body .visitor-profile-panel .visitor-profile-row span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}
html body .visitor-profile-panel .visitor-profile-row[hidden] {
  display: none;
}
html body .visitor-profile-panel .visitor-profile-row svg {
  flex: none;
  width: 14px;
  height: 14px;
  opacity: 0.6;
}
html body .visitor-profile-panel .visitor-profile-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  justify-self: stretch;
  gap: 8px;
  margin-top: 10px;
}
html body .visitor-profile-panel .visitor-profile-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-width: 100px;
  min-height: 32px;
  height: 32px;
  padding: 0 12px;
  margin: 0;
  border-radius: 7px;
  font-size: 13px;
  text-decoration: none;
}
html body .visitor-profile-panel .visitor-profile-actions button svg {
  width: 13px;
  height: 13px;
}
html body .visitor-profile-panel .visitor-profile-actions button:disabled {
  opacity: 0.45;
  cursor: default;
}
html body .visitor-profile-panel > .visitor-privacy-link.visitor-privacy-link {
  min-height: 0;
  margin: 12px 0 0;
  padding: 2px 0;
  border: 0;
  text-align: center;
  text-decoration: none;
  font-size: 11px;
  color: var(--site-secundario, var(--muted, #555));
}
html body .visitor-profile-panel > .visitor-privacy-link.visitor-privacy-link:hover {
  color: inherit;
}
/* Edição: nome e WhatsApp juntos, com rótulos visíveis. */
html body .visitor-dialog .visitor-edit-label {
  display: grid;
  gap: 4px;
  margin: 0 0 10px;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
}
html body .visitor-dialog .visitor-privacy-link {
  text-decoration: none;
  font-weight: 600;
}

/* Diálogo de identificação e edição mais compacto (28/10/2026). */
html body .visitor-dialog {
  width: min(360px, calc(100vw - 24px));
  padding: 22px 22px 16px;
}
html body .visitor-dialog #visitor-title {
  margin: 0 0 16px;
  font-size: 22px;
  line-height: 1.2;
}
html body .visitor-dialog input:not([type="checkbox"]) {
  height: 38px;
  min-height: 38px;
  padding: 0 10px;
  font-size: 14px;
}
html body .visitor-dialog .visitor-edit-label {
  margin: 0 0 10px;
  font-size: 13px;
}
html body .visitor-dialog .visitor-remember {
  margin: 4px 0 0;
  font-size: 13px;
}
html body .visitor-dialog .visitor-opcional {
  color: var(--site-secundario, var(--muted, #666));
  font-weight: 400;
}
html body .visitor-dialog .visitor-actions {
  margin-top: 14px;
}
html body .visitor-dialog .visitor-actions button {
  min-height: 38px;
  height: 38px;
  padding: 0 14px;
  font-size: 14px;
}
html body .visitor-dialog .visitor-privacy-line {
  margin: 10px 0 0;
  text-align: center;
}
html body .visitor-dialog .visitor-privacy-line .visitor-privacy-link {
  min-height: 0;
  padding: 2px 0;
  border: 0;
  background: none;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  color: var(--site-secundario, var(--muted, #555));
}

/* Identificação em etapas usa a pergunta como título, sem repetir o rótulo. */
.visitor-dialog-etapas section > label { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); }
html body .visitor-dialog label { font-size:14px; margin:14px 0 7px; }
html body .visitor-dialog .visitor-note { margin:7px 0 0; }
html body .visitor-dialog .visitor-actions button { height:42px; }
@media(max-width:480px){html body .visitor-dialog{padding:22px;}html body .visitor-dialog #visitor-title{font-size:23px;margin-bottom:18px;}}

/* O indicador confirma somente o contato salvo neste navegador. */
.visitor-profile > summary { position: relative; }
.visitor-contact-status {
  position: absolute;
  right: 4px;
  bottom: 4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--contact-status-color, currentColor);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--contact-status-color, currentColor) 60%, var(--header-bg, var(--surface)));
}
.visitor-contact-status[hidden] { display: none; }
.quote-contact label[hidden],
.pet-checkout label[hidden],
#agBookingForm label[hidden] { display: none !important; }
