/* Public website only: keep the existing 16px reading baseline and heading sizes. */
.marketing-page,
.clasp-public-page {
  font-family: system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.6;
}

.marketing-page .navlinks a,
.marketing-page .button,
.marketing-page .marketing-menu,
.marketing-page .step p,
.marketing-page .guide-card p,
.marketing-page .pricecard li,
.marketing-page details p,
.marketing-page .fine,
.marketing-page .marketing-note,
.marketing-page .trades,
.marketing-page .chat,
.marketing-page .trial-line,
.marketing-page .pricing-conditions,
.marketing-page .plan-billing,
.marketing-page .plan-promise,
.marketing-page .comparison-jump,
.marketing-page .report-library-grid ul,
.marketing-page .junior-report-example,
.marketing-page .junior-report-example p,
.marketing-page .comparison-table,
.marketing-page .comparison-table thead th,
.marketing-page .comparison-table td {
  font-size: 16px;
  line-height: 1.6;
}

.marketing-page .marketing-menu {
  font-family: inherit;
}

.marketing-page.pricing-page .pricecard h2 {
  font-size: 27px;
}

.marketing-page .eyebrow,
.marketing-page .number,
.marketing-page .pill,
.marketing-page.pricing-page .pricecard .pill,
.marketing-page .breadcrumb,
.marketing-page footer,
.marketing-page .comparison-table .feature-detail,
.marketing-page .comparison-table thead span,
.marketing-page .comparison-table .comparison-group th {
  font-size: 14px;
  line-height: 1.6;
}

.clasp-public-page p,
.clasp-public-page li {
  line-height: 1.6;
}

.clasp-public-page p.text-sm,
.clasp-public-page li.text-sm {
  font-size: 16px;
}

.clasp-public-page footer,
.clasp-public-page footer a,
.clasp-public-page nav {
  font-size: 14px;
  line-height: 1.6;
}

/* Four and ten peer cards use complete two-column rows instead of 3 + 1. */
@media (min-width: 701px) {
  .marketing-page .marketing-cards:has(> article:nth-child(4):last-child),
  .marketing-page .marketing-cards:has(> article:nth-child(10):last-child) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1100px) {
  .marketing-page .marketing-cards:has(> article:nth-child(5):last-child),
  .marketing-page .marketing-cards:has(> article:nth-child(8):last-child) {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .marketing-page .marketing-cards:has(> article:nth-child(5):last-child) > article,
  .marketing-page .marketing-cards:has(> article:nth-child(8):last-child) > article {
    grid-column: span 2;
  }

  .marketing-page .marketing-cards:has(> article:nth-child(5):last-child) > article:nth-child(4),
  .marketing-page .marketing-cards:has(> article:nth-child(8):last-child) > article:nth-child(7) {
    grid-column: 2 / span 2;
  }

  .marketing-page .marketing-cards:has(> article:nth-child(5):last-child) > article:nth-child(5),
  .marketing-page .marketing-cards:has(> article:nth-child(8):last-child) > article:nth-child(8) {
    grid-column: 4 / span 2;
  }
}

@media (min-width: 1000px) {
  .marketing-page .guide-cards:has(> article:nth-child(3):last-child) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 701px) and (max-width: 1099px) {
  .marketing-page .marketing-cards:has(> article:nth-child(3):last-child) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .marketing-page .marketing-cards:has(> article:nth-child(5):last-child) > article:last-child {
    grid-column: 1 / -1;
  }
}

@media (max-width: 999px) {
  .marketing-page .guide-cards:has(> article:nth-child(3):last-child) {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 700px) {
  .marketing-page .marketing-cards {
    grid-template-columns: 1fr;
  }
}

/* Keep the comparison readable on phones instead of shrinking its text. */
@media (max-width: 600px) {
  .marketing-page.pricing-page .pricecard h2 {
    font-size: 32px;
  }

  .marketing-page.pricing-page .amount {
    font-size: 66px;
  }

  .marketing-page .comparison-table,
  .marketing-page .comparison-table thead,
  .marketing-page .comparison-table tbody {
    display: block;
    width: 100%;
  }

  .marketing-page .comparison-table tr {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .marketing-page .comparison-table th:first-child {
    grid-column: 1 / -1;
    width: auto;
  }

  .marketing-page .comparison-table thead th:not(:first-child) {
    text-align: center;
  }

  .marketing-page .comparison-table th,
  .marketing-page .comparison-table td {
    padding: 14px;
  }

  .marketing-page .comparison-table tbody td::before {
    display: block;
    margin-bottom: 4px;
    font-size: 14px;
    font-weight: 700;
  }

  .marketing-page .comparison-table tbody td:first-of-type::before {
    content: "Clasp";
  }

  .marketing-page .comparison-table tbody td:last-of-type::before {
    content: "Clasp Pro";
  }
}

/* The shared support widget keeps public typography without affecting app screens. */
body.marketing-page .clasp-support-link,
body.marketing-page .clasp-support-dialog,
body.marketing-page .clasp-support-toolbar button,
body:has(.clasp-public-page) .clasp-support-link,
body:has(.clasp-public-page) .clasp-support-dialog,
body:has(.clasp-public-page) .clasp-support-toolbar button {
  font-family: system-ui, -apple-system, sans-serif;
}

body.marketing-page .clasp-support-dialog,
body:has(.clasp-public-page) .clasp-support-dialog {
  font-size: 16px;
  line-height: 1.6;
}

body.marketing-page .clasp-support-footer,
body:has(.clasp-public-page) .clasp-support-footer {
  font-size: 14px;
  line-height: 1.6;
}

/* First-party public pages use the same square controls as the workspace. */
body :not(.phone-shell, .phone-viewport, .business-site, .business-site *, svg, svg *) { border-radius: 0 !important; }
