/**
 * Páginas legais, modal de privacidade e confirmação (obrigado)
 */

/* —— Modal privacidade —— */
.privacy-dialog {
  width: min(42rem, calc(100vw - 2rem));
  max-height: min(88vh, 52rem);
  margin: auto;
  padding: 0;
  border: none;
  border-radius: 0.25rem;
  background: transparent;
  overflow: visible;
}

.privacy-dialog::backdrop {
  background: oklch(0.2 0.04 250 / 0.55);
  backdrop-filter: blur(4px);
}

.privacy-dialog__panel {
  display: flex;
  flex-direction: column;
  max-height: min(88vh, 52rem);
  background: var(--background, #fff);
  border: 1px solid var(--border, oklch(0.92 0.01 250));
  border-top: 3px solid var(--secondary, oklch(0.55 0.14 155));
  border-radius: 0.25rem;
  box-shadow: 0 24px 60px oklch(0.18 0.04 250 / 0.35);
  overflow: hidden;
}

.privacy-dialog__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.375rem 1rem;
  background: oklch(0.98 0.01 250);
  border-bottom: 1px solid var(--border, oklch(0.92 0.01 250));
}

.privacy-dialog__kicker {
  margin: 0 0 0.3rem;
  font-size: 0.625rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--secondary, oklch(0.5 0.13 155));
}

.privacy-dialog__title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1.2;
  color: var(--primary, oklch(0.3 0.08 250));
}

.privacy-dialog__close {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  color: var(--primary, oklch(0.3 0.08 250));
  background: #fff;
  border: 1px solid var(--border, oklch(0.9 0.01 250));
  border-radius: 0.25rem;
  cursor: pointer;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease;
}

.privacy-dialog__close:hover {
  color: #fff;
  background: var(--primary, oklch(0.3 0.08 250));
  border-color: var(--primary, oklch(0.3 0.08 250));
}

.privacy-dialog__body {
  padding: 1.25rem 1.375rem;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.privacy-dialog__footer {
  padding: 0.875rem 1.375rem 1.125rem;
  border-top: 1px solid var(--border, oklch(0.92 0.01 250));
  background: oklch(0.98 0.006 250);
}

.privacy-dialog__fullpage {
  display: inline-flex;
  align-items: center;
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--secondary, oklch(0.48 0.14 155));
  text-decoration: underline;
  text-underline-offset: 2px;
}

body.privacy-dialog-open {
  overflow: hidden;
}

/* —— Documento privacidade —— */
.privacy-doc__lead {
  margin: 0 0 1.5rem;
  font-size: 0.9375rem;
  line-height: 1.65;
  color: var(--muted-foreground, oklch(0.45 0.02 250));
}

.privacy-doc__section {
  margin-bottom: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border, oklch(0.94 0.01 250));
}

.privacy-doc__section:last-of-type {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.privacy-doc__heading {
  margin: 0 0 0.65rem;
  font-size: 1rem;
  font-weight: 700;
  color: var(--primary, oklch(0.3 0.08 250));
}

.privacy-doc--compact .privacy-doc__heading {
  font-size: 0.9375rem;
}

.privacy-doc__p {
  margin: 0 0 0.65rem;
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--muted-foreground, oklch(0.48 0.02 250));
}

.privacy-doc__p:last-child {
  margin-bottom: 0;
}

.privacy-doc__meta {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border, oklch(0.92 0.01 250));
}

.privacy-doc__meta-line {
  margin: 0 0 0.35rem;
  font-size: 0.8125rem;
  color: var(--muted-foreground, oklch(0.5 0.02 250));
}

.privacy-doc__meta a {
  font-weight: 700;
  color: var(--secondary, oklch(0.48 0.14 155));
}

/* —— Shell páginas legais —— */
.legal-page {
  min-height: 100vh;
  background: oklch(0.97 0.006 250);
}

.legal-shell__header {
  background: var(--gradient-primary, linear-gradient(135deg, oklch(0.28 0.08 250), oklch(0.32 0.09 250)));
  border-bottom: 3px solid var(--secondary, oklch(0.55 0.14 155));
}

.legal-shell__header--minimal {
  border-bottom-width: 0;
}

.legal-shell__header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 48rem;
  margin: 0 auto;
  padding: 1rem 1.25rem;
}

.legal-shell__brand img {
  display: block;
  height: 2.5rem;
  width: auto;
  max-width: 10.5rem;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.legal-shell__back {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.8125rem;
  font-weight: 700;
  color: oklch(1 0 0 / 0.92);
  text-decoration: none;
  transition: color 0.2s ease;
}

.legal-shell__back:hover {
  color: oklch(0.9 0.1 155);
}

.legal-shell__hero {
  max-width: 48rem;
  margin: 0 auto;
  padding: 0 1.25rem 1.75rem;
}

.legal-shell__kicker {
  margin: 0 0 0.4rem;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: oklch(0.85 0.12 155);
}

.legal-shell__title {
  margin: 0;
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #fff;
}

.legal-page__main {
  max-width: 48rem;
  margin: 0 auto;
  padding: 2rem 1.25rem 3rem;
}

.legal-page__main--center {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 5rem);
  padding-top: 2.5rem;
  padding-bottom: 2.5rem;
}

.legal-page__card {
  padding: 1.75rem 1.5rem;
  background: #fff;
  border: 1px solid var(--border, oklch(0.92 0.01 250));
  border-radius: 0.25rem;
  box-shadow: 0 14px 40px oklch(0.22 0.04 250 / 0.08);
}

@media (min-width: 640px) {
  .legal-page__card {
    padding: 2.25rem 2rem;
  }
}

/* —— Obrigado —— */
.thanks-card {
  width: 100%;
  max-width: 32rem;
  padding: 2rem 1.5rem;
  text-align: center;
  background: #fff;
  border: 1px solid var(--border, oklch(0.92 0.01 250));
  border-top: 3px solid var(--secondary, oklch(0.55 0.14 155));
  border-radius: 0.25rem;
  box-shadow: 0 20px 50px oklch(0.22 0.04 250 / 0.12);
  animation: thanks-card-in 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.thanks-card--whatsapp {
  border-top-color: #25d366;
}

@keyframes thanks-card-in {
  from {
    opacity: 0;
    transform: translateY(1.25rem) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.thanks-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 4.5rem;
  height: 4.5rem;
  margin: 0 auto 1.25rem;
  color: #fff;
  background: var(--secondary, oklch(0.55 0.14 155));
  border-radius: 0.25rem;
  box-shadow: 0 10px 28px oklch(0.55 0.14 155 / 0.35);
}

.thanks-card--whatsapp .thanks-card__icon {
  background: #25d366;
  box-shadow: 0 10px 28px oklch(0.62 0.16 155 / 0.35);
}

.thanks-card__kicker {
  margin: 0 0 0.35rem;
  font-size: 0.625rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--secondary, oklch(0.5 0.13 155));
}

.thanks-card__title {
  margin: 0 0 0.75rem;
  font-size: clamp(1.5rem, 4vw, 1.875rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--primary, oklch(0.3 0.08 250));
}

.thanks-card__lead {
  margin: 0 0 1.5rem;
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--muted-foreground, oklch(0.48 0.02 250));
}

.thanks-card__lead strong {
  color: var(--primary, oklch(0.3 0.08 250));
  font-weight: 700;
}

.thanks-card__steps {
  margin: 0 0 1.75rem;
  padding: 0;
  list-style: none;
  text-align: left;
}

.thanks-card__step {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border, oklch(0.94 0.01 250));
  font-size: 0.875rem;
  line-height: 1.45;
  color: var(--muted-foreground, oklch(0.52 0.02 250));
}

.thanks-card__step:last-child {
  border-bottom: none;
}

.thanks-card__step-num {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 1.75rem;
  height: 1.75rem;
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--muted-foreground, oklch(0.55 0.02 250));
  background: oklch(0.96 0.006 250);
  border: 1px solid var(--border, oklch(0.92 0.01 250));
  border-radius: 0.25rem;
}

.thanks-card__step.is-done .thanks-card__step-num {
  color: #fff;
  background: var(--secondary, oklch(0.55 0.14 155));
  border-color: var(--secondary, oklch(0.55 0.14 155));
}

.thanks-card__step.is-active .thanks-card__step-num {
  color: #fff;
  background: var(--primary, oklch(0.3 0.08 250));
  border-color: var(--primary, oklch(0.3 0.08 250));
  box-shadow: 0 0 0 2px oklch(0.55 0.14 155 / 0.35);
}

.thanks-card__step.is-active .thanks-card__step-text {
  font-weight: 600;
  color: var(--primary, oklch(0.3 0.08 250));
}

.thanks-card__actions {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

@media (min-width: 480px) {
  .thanks-card__actions {
    flex-direction: row;
    justify-content: center;
  }
}

.thanks-card__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 3rem;
  padding: 0 1.25rem;
  font-size: 0.9375rem;
  font-weight: 700;
  text-decoration: none;
  border-radius: 0.25rem;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.thanks-card__btn--primary {
  color: #fff;
  background: var(--primary, oklch(0.3 0.08 250));
  box-shadow: 0 8px 24px oklch(0.22 0.04 250 / 0.22);
}

.thanks-card__btn--primary:hover {
  transform: translateY(-2px);
}

.thanks-card__btn--secondary {
  color: var(--primary, oklch(0.3 0.08 250));
  background: #fff;
  border: 1px solid var(--border, oklch(0.9 0.01 250));
}

.thanks-card__btn .lucide,
.thanks-card__btn svg {
  width: 1.125rem;
  height: 1.125rem;
}

.thanks-card__note {
  margin: 1.25rem 0 0;
  font-size: 0.75rem;
  line-height: 1.5;
  color: var(--muted-foreground, oklch(0.55 0.02 250));
}

.thanks-card__note a {
  font-weight: 700;
  color: var(--secondary, oklch(0.48 0.14 155));
}

.lead-form__privacy-link {
  font-weight: 700;
  color: var(--secondary, oklch(0.48 0.14 155));
  text-decoration: underline;
  text-underline-offset: 2px;
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  cursor: pointer;
}

.lead-form__privacy-link:hover {
  color: var(--primary, oklch(0.3 0.08 250));
}

@media (prefers-reduced-motion: reduce) {
  .thanks-card {
    animation: none;
  }

  .privacy-dialog,
  .privacy-dialog::backdrop {
    animation: none;
  }

  .thanks-card__btn:hover {
    transform: none;
  }
}
