/* App captures always retain their top/header when a legacy frame crops them. */
body img[src*="/tool-screenshots/"],
body img[src*="/phone-screen-"] {
  object-position: center top;
}

/*
 * Content rhythm overrides only. The homepage and gender quiz are deliberately
 * excluded; shared site chrome is handled separately in footer.css.
 */
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .shell,
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .center-shell {
  width: min(1280px, calc(100% - 40px));
}

/* Model-rendered guides, feature pages, editorial, pricing and integrations. */
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) :is(.page-hero, .wearable-hero) {
  padding-top: 38px;
  padding-bottom: 34px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .feature-page {
  padding-bottom: 48px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .feature-groups {
  gap: 30px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .feature-group h2 {
  margin: 0 0 12px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .feature-tile {
  min-height: 150px;
  padding: 17px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .tile-mark {
  margin-bottom: 15px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) :is(.pricing, .faq, .wearable-reading, .wearable-faq) {
  padding-top: 46px;
  padding-bottom: 46px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .plan-compare {
  padding-bottom: 38px;
  gap: 14px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .plan-compare article {
  padding: 24px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .pricing-notes {
  gap: 14px;
  padding-bottom: 48px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .trimester-navigation {
  gap: 12px;
  margin-top: 28px;
  margin-bottom: 42px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) :is(.trimester-navigation article, .pillar-reading article) {
  padding: 21px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .pillar-reading {
  gap: 12px;
  margin-bottom: 46px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .wearable-hero {
  gap: 38px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .wearable-copy {
  gap: 22px 38px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .article {
  gap: 38px;
  padding-bottom: 46px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .article section {
  padding: 19px 0;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .section-head {
  margin-bottom: 20px;
}

/* Center templates: retain their alternating color fields while trimming air. */
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .center-hero {
  padding: 38px 0;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .center-hero-grid {
  gap: 34px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .center-section {
  padding: 46px 0;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .center-section-head {
  margin-bottom: 20px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) :is(.center-tools, .center-steps) {
  gap: 12px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .center-callout {
  padding: 21px;
  gap: 20px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) .center-cta {
  padding: 40px 0;
}

/* Legacy resource, legal/support, guide, blog and editorial templates. */
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .back-home {
  width: min(1280px, calc(100% - 40px));
  margin-top: 4px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page > .header,
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .resource-page > :is(.hero, .blog-hero, .header) {
  width: min(1280px, calc(100% - 40px));
  margin-top: 14px;
  padding-top: clamp(26px, 3vw, 42px);
  padding-bottom: clamp(26px, 3vw, 42px);
  border-radius: 22px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .resource-page > .hero {
  min-height: 260px;
  padding-right: clamp(20px, 3vw, 40px);
  padding-left: clamp(20px, 3vw, 40px);
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page :is(.content, .container) {
  padding-top: 32px;
  padding-bottom: 44px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page :is(.content, .container) > h2 {
  margin-top: 30px;
  margin-bottom: 10px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page :is(.content, .container) > h2:first-child {
  margin-top: 0;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .hero-content {
  padding-top: 38px;
  padding-bottom: 38px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .split-text {
  padding: 32px 28px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .split-section {
  min-height: 390px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .photo-break {
  height: 40vh;
  min-height: 270px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .resource-page :is(.section-wrap, .section-wrapper, .section, .blog, .features, .products, .faq, .how-it-works, .tales, .quiz-highlights, .the-wait, .timeline-section, .share-section, .share-cta, .cta-section, .related-section, .app-highlights-section) {
  width: min(1280px, calc(100% - 40px));
  padding-top: 42px;
  padding-bottom: 42px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .resource-page :is(.blog-grid, .features-grid, .products-grid, .timeline-grid, .related-grid) {
  gap: 14px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page :is(.blog-card, .feature-card, .perm-card, .step-card, .tale-card) {
  padding: 20px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page :is(.faq-list, .highlight-list, .tales-grid, .feature-pills) {
  margin-top: 26px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page :is(.faq-item summary, .faq-item p) {
  padding-right: 19px;
  padding-left: 19px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .faq-item summary {
  padding-top: 16px;
  padding-bottom: 16px;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .faq-item p {
  padding-bottom: 16px;
}

/* Constrain legacy inline hero spacing only; do not flatten section colors. */
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page :is(.resource-page > .hero, .resource-page > .blog-hero, .resource-page > .header)[style*="padding"],
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page :is(.hero-content, .split-text)[style*="padding"] {
  padding-top: 38px !important;
  padding-bottom: 38px !important;
}
body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .resource-page > :is(.hero, .blog-hero, .header)[style*="margin-top"] {
  margin-top: 14px !important;
}

@media (max-width: 767px) {
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) :is(.shell, .center-shell) {
    width: calc(100% - 28px);
  }
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) :is(.page-hero, .wearable-hero, .center-hero) {
    padding-top: 30px;
    padding-bottom: 30px;
  }
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) :is(.pricing, .faq, .wearable-reading, .wearable-faq, .center-section) {
    padding-top: 36px;
    padding-bottom: 36px;
  }
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) :is(.article, .wearable-copy) {
    gap: 20px;
  }
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']) :is(.feature-group > div, .pricing-notes, .plan-compare, .trimester-navigation) {
    grid-template-columns: minmax(0, 1fr);
  }
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .back-home,
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page :is(.content, .container) {
    width: calc(100% - 30px);
  }
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page > .header,
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .resource-page > :is(.hero, .blog-hero, .header) {
    width: calc(100% - 30px);
    margin-top: 12px;
    padding: 27px 20px;
    border-radius: 18px;
  }
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page :is(.content, .container) {
    padding-top: 26px;
    padding-bottom: 36px;
  }
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .hero-content {
    padding: 66px 20px 32px;
  }
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .split-text {
    padding: 28px 22px;
  }
  body:not([data-website-page='/']):not([data-website-page='/babygenderquiz']):not([data-website-page='/baby-gender-quiz']).legacy-page .resource-page :is(.section-wrap, .section-wrapper, .section, .blog, .features, .products, .faq, .how-it-works, .tales, .quiz-highlights, .the-wait, .timeline-section, .share-section, .share-cta, .cta-section, .related-section, .app-highlights-section) {
    width: calc(100% - 30px);
    padding-top: 34px;
    padding-bottom: 34px;
  }
}
