/* Shared conversion and responsive guardrails for TestEarth static pages. */
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

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

body {
  overflow-x: clip;
}

img, svg, canvas, video, iframe {
  max-width: 100%;
}

button,
[role="button"],
a[href],
input,
select,
textarea {
  touch-action: manipulation;
}

input,
select,
textarea,
button {
  font: inherit;
}

input[type="email"],
input[type="text"],
input[type="tel"],
input[type="number"],
input[type="password"],
input[type="search"],
select,
textarea {
  max-width: 100%;
}

h1, h2, h3, h4, h5, h6,
p, li, label, button, a, input, textarea {
  overflow-wrap: anywhere;
}

table {
  max-width: 100%;
}

@media (max-width: 760px) {
  body {
    min-width: 0 !important;
  }

  main,
  section,
  article,
  header,
  footer,
  nav,
  .container,
  .wrapper,
  .wrap,
  .page,
  .shell,
  .main,
  .content,
  .hero,
  .hero-inner,
  .quiz-container,
  .quiz-wrap,
  .checkout-container,
  .checkout-wrap,
  .checkout-layout,
  .checkout-grid,
  .email-gate,
  .score-reveal,
  .paywall,
  .modal,
  .card,
  .panel {
    max-width: 100% !important;
  }

  .container,
  .wrapper,
  .wrap,
  .page,
  .shell,
  .main,
  .content,
  main,
  section,
  article {
    padding-left: max(14px, env(safe-area-inset-left)) !important;
    padding-right: max(14px, env(safe-area-inset-right)) !important;
  }

  .top-bar,
  .navbar,
  .nav,
  .site-header,
  header {
    padding-left: max(14px, env(safe-area-inset-left)) !important;
    padding-right: max(14px, env(safe-area-inset-right)) !important;
    gap: 10px;
  }

  .hero,
  .hero-grid,
  .checkout-layout,
  .checkout-grid,
  .pricing-grid,
  .feature-grid,
  .features,
  .benefits,
  .cards,
  .stats,
  .columns,
  .two-col,
  .grid {
    grid-template-columns: 1fr !important;
  }

  .option-grid,
  .answers,
  .answer-grid,
  .quiz-options,
  .options {
    grid-template-columns: 1fr !important;
  }

  .eg-form,
  .email-form,
  .form-row,
  .input-row,
  .checkout-form,
  .lead-form {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 10px !important;
  }

  input[type="email"],
  input[type="text"],
  input[type="tel"],
  input[type="number"],
  input[type="password"],
  input[type="search"],
  select,
  textarea {
    width: 100% !important;
    min-height: 48px;
    font-size: 16px !important;
  }

  button,
  input[type="submit"],
  .btn,
  .button,
  .btn-start,
  .cta-btn,
  .eg-btn,
  .submit-btn,
  .card-btn,
  .pay-btn,
  .primary-btn,
  .checkout-btn {
    min-height: 48px;
    white-space: normal;
    line-height: 1.2;
  }

  .eg-form button,
  .email-form button,
  .form-row button,
  .input-row button,
  .lead-form button,
  .btn-start,
  .cta-btn,
  .eg-btn,
  .submit-btn,
  .pay-btn,
  .primary-btn,
  .checkout-btn {
    width: 100%;
  }

  .trust,
  .badges,
  .logos,
  .social-proof,
  .stats,
  .benefits {
    flex-wrap: wrap;
  }

  table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  body.te-has-mobile-sticky-cta {
    padding-bottom: 84px;
  }

  .te-mobile-sticky-cta {
    position: fixed !important;
    left: max(14px, env(safe-area-inset-left)) !important;
    right: max(14px, env(safe-area-inset-right)) !important;
    bottom: max(12px, env(safe-area-inset-bottom)) !important;
    z-index: 9999 !important;
    width: auto !important;
    max-width: none !important;
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.22) !important;
  }
}

@media (max-width: 420px) {
  h1 {
    line-height: 1.08;
  }

  h2,
  h3 {
    line-height: 1.15;
  }

  .top-bar,
  .navbar,
  .nav,
  .site-header {
    min-height: 56px;
  }
}
