/*
 * Shared styles for the /tools/ landing pages (tool-page.php), in the Showcase's style (showcase/src/style.css):
 * pill buttons and nav items (.main-button, .sidebar-section), the 60 px top bar with a divider (.topbar),
 * cards on a surface with 8 px corners, no bordered buttons. Colors come from /css/main.css's variables
 * ([data-mode], [data-theme]) and the user's color theme (appTheme.js), mapped onto the Showcase's roles:
 * --bg-color = --bg-main, --bg-color-faint = --bg-main-80, --secondary-accent = --accent.
 *
 * Things that sit on the page or on a surface (chips, secondary buttons, hovers) are mixes of the text color
 * over what's behind them, so they show on both: main.css's --bg-color-hover and --bg-color-faint are the same
 * color in some palettes.
 *
 * The footer also works without the page (.tp): apps outside tool-page.php show it too (the FM26 to FM27
 * converter's Footer.vue, on the kit creator's style.css instead of main.css), so it gets the variables itself
 * and doesn't count on main.css's reset.
 */

.tp,
.tp-footer {
  --tp-max: 1120px;
  --tp-gutter: 24px;
  --tp-radius: 8px;
  --tp-radius-pill: 32px;
  --tp-header-height: 60px;
  --tp-text: var(--text-color-100);
  --tp-text-soft: var(--text-color-70);
  --tp-text-faint: var(--text-color-50);
  --tp-divider: var(--bg-color-hover);
  --tp-surface: var(--bg-color-faint);
  --tp-surface-hover: color-mix(in srgb, var(--text-color-100) 6%, var(--tp-surface));
  /* a fill over the page or a surface: secondary buttons, nav hovers */
  --tp-fill: color-mix(in srgb, var(--text-color-100) 9%, transparent);
}

.tp {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  color-scheme: light;
}

[data-theme="dark"] .tp {
  color-scheme: dark;
}

.tp em {
  font-style: italic;
}

.tp code,
.tp kbd {
  border-radius: 4px;
  background: color-mix(in srgb, currentColor 12%, transparent);
  overflow-wrap: anywhere;
}

.tp code {
  padding: 1px 4px;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 0.9em;
}

.tp kbd {
  display: inline-block;
  min-width: 1.6em;
  padding: 0 5px;
  font-size: 0.85em;
  font-weight: 700;
  line-height: 1.6;
  text-align: center;
}

.tp :focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px var(--focus);
}

.tp-container {
  width: 100%;
  max-width: var(--tp-max);
  margin: 0 auto;
  padding: 0 var(--tp-gutter);
}

.tp-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.tp-skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  padding: 8px 12px;
  border-radius: 4px;
  background: var(--primary-accent);
  color: var(--text-on-primary-accent);
}

.tp-skip-link:focus {
  top: 12px;
}

/* An app embedded in the template (.tp-app): its form fields take the page's text color, not main.css's
   #222 (which the template loads for the rest of the site) */
.tp-app :is(input, select, textarea) {
  color: inherit;
}

/* Buttons: the Showcase's .main-button, filled (no outlined variant). Not inside an app embedded in the
   template (.tp-app, e.g. the FM27 Kit Font Maker), which keeps the kit creator's buttons. */

.tp .button:not(:where(.tp-app *)) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 6px 16px;
  border: 0;
  border-radius: var(--tp-radius-pill);
  background-color: var(--primary-accent);
  color: var(--text-on-primary-accent);
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}

.tp .button:not(:where(.tp-app *)):hover:not([disabled]) {
  opacity: 0.7;
}

.tp .button:not(:where(.tp-app *))[disabled] {
  cursor: not-allowed;
  opacity: 0.5;
}

/* the main action (the Showcase's Login and Publish) */
.tp .button-accent:not(:where(.tp-app *)) {
  background-color: var(--secondary-accent);
  color: var(--text-on-secondary-accent);
}

.tp .button-secondary:not(:where(.tp-app *)) {
  background-color: var(--tp-fill);
  color: var(--text-color-100);
}

.tp .button-lg:not(:where(.tp-app *)) {
  min-height: 46px;
  padding: 8px 24px;
  font-size: 15px;
}

/* the kit creator's logo in its buttons, like the Showcase's sidebar button */
.tp .button .tp-logo {
  width: 20px;
  height: 20px;
}

.tp .button-lg :is(.tp-icon, .tp-logo) {
  width: 24px;
  height: 24px;
}

/* round icon buttons (the top bar's back button, the theme toggle; also in the footer of apps) */
:is(.tp, .tp-footer) .icon-button:not(:where(.tp-app *)) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  background: none;
  border: none;
  border-radius: 100%;
  color: var(--text-color-100);
  cursor: pointer;
}

:is(.tp, .tp-footer) .icon-button:not(:where(.tp-app *)):hover:not([disabled]) {
  background-color: var(--tp-fill);
}

/* Header: the Showcase's top bar, nav links as its sidebar items */

.tp-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--bg-color);
  border-bottom: 1px solid var(--tp-divider);
}

.tp-header__inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: var(--tp-header-height);
}

.tp-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--tp-text);
  font-weight: 700;
  font-size: 18px;
  text-decoration: none;
  white-space: nowrap;
}

.tp-logo {
  width: 28px;
  height: 28px;
}

.tp-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.tp-nav__link {
  display: flex;
  align-items: center;
  padding: 8px 16px;
  border-radius: var(--tp-radius-pill);
  color: var(--tp-text);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

.tp-nav__link:hover,
.tp-nav__link[aria-current="page"] {
  background: var(--tp-fill);
}

.tp .tp-nav__cta {
  display: none;
}

.tp-header__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.tp-theme-toggle__sun,
[data-theme="dark"] .tp-theme-toggle__moon {
  display: none;
}

[data-theme="dark"] .tp-theme-toggle__sun {
  display: block;
}

.tp .tp-menu-toggle {
  display: none;
}

.tp-menu-toggle .tp-icon {
  width: 24px;
  height: 24px;
}

/* Sections */

.tp-main {
  flex: 1;
}

.tp-section {
  padding: 72px 0;
}

.tp-section--alt {
  border-top: 1px solid var(--tp-divider);
}

/* the closing panel follows a section with its own bottom space */
.tp-section--cta {
  padding-top: 0;
}

.tp-section-head {
  max-width: 680px;
  margin: 0 auto 40px;
  text-align: center;
}

/* the creator's section labels (.add-layer-header) */
.tp-eyebrow {
  display: block;
  margin-bottom: 8px;
  color: var(--tp-text-soft);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.tp-h2 {
  font-size: clamp(26px, 3.5vw, 34px);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.tp-lead {
  margin-top: 12px;
  color: var(--tp-text-soft);
  font-size: 17px;
  line-height: 1.55;
}

.tp a.tp-link {
  color: var(--tp-text);
  text-decoration: underline;
  text-decoration-color: var(--secondary-accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.tp a.tp-link:hover {
  text-decoration-color: currentColor;
}

.tp-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 28px;
}

.tp-actions--center {
  justify-content: center;
}

/* Breadcrumbs (tp_breadcrumbs) */

.tp-breadcrumbs {
  padding-top: 24px;
  color: var(--tp-text-faint);
  font-size: 14px;
}

.tp-breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  row-gap: 4px;
}

.tp-breadcrumbs li {
  display: inline-flex;
  align-items: center;
}

.tp-breadcrumbs a {
  color: var(--tp-text-soft);
  text-decoration: none;
}

.tp-breadcrumbs a:hover {
  color: var(--tp-text);
  text-decoration: underline;
}

.tp-breadcrumbs .tp-icon {
  width: 14px;
  height: 14px;
  margin: 0 6px;
}

.tp-breadcrumbs [aria-current="page"] {
  color: var(--tp-text);
  font-weight: 700;
}

/* Hero */

.tp-hero {
  padding: 64px 0 72px;
}

.tp-hero__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  align-items: center;
  gap: 56px;
}

/* no image: the text alone (the /tools/ page) */
.tp-hero__inner--text {
  grid-template-columns: minmax(0, 1fr);
}

.tp-hero__inner--text .tp-hero__lead {
  max-width: 680px;
}

/* the breadcrumbs (and their JSON-LD script) come first */
.tp-breadcrumbs ~ .tp-hero {
  padding-top: 32px;
}

.tp-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 16px;
}

/* the creator's .upcoming-status */
.tp-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--tp-fill);
  color: var(--tp-text);
  font-size: 12px;
}

.tp-badge--accent {
  background: var(--secondary-accent);
  color: var(--text-on-secondary-accent);
}

.tp-h1 {
  font-size: clamp(36px, 5.5vw, 52px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.tp-h1 span {
  color: var(--secondary-accent);
}

.tp-hero__lead {
  margin-top: 20px;
  max-width: 540px;
  color: var(--tp-text-soft);
  font-size: 18px;
  line-height: 1.55;
}

.tp-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin-top: 16px;
  color: var(--tp-text-faint);
  font-size: 14px;
}

.tp-meta li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.tp-meta .tp-icon {
  width: 16px;
  height: 16px;
}

/* Image slots (tp_media) */

.tp-media {
  position: relative;
  aspect-ratio: 16 / 10;
  border-radius: var(--tp-radius);
  overflow: hidden;
  background: var(--tp-surface);
  box-shadow: var(--shadow);
}

.tp-media__open {
  display: block;
  height: 100%;
  cursor: zoom-in;
}

/* no box of its own: the <img> fills the slot */
.tp-media picture {
  display: contents;
}

.tp-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tp-media--placeholder {
  box-shadow: none;
  background:
    repeating-linear-gradient(
      -45deg,
      transparent 0 14px,
      color-mix(in srgb, var(--text-color-100) 4%, transparent) 14px 28px
    ),
    var(--tp-surface);
}

.tp-media__placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px;
  text-align: center;
  color: var(--tp-text-faint);
}

.tp-media__placeholder .tp-icon {
  width: 36px;
  height: 36px;
}

.tp-media__label {
  max-width: 360px;
  color: var(--tp-text-soft);
  font-size: 14px;
  font-weight: 700;
}

.tp .tp-media__file {
  font-size: 12px;
}

/* Feature cards (tp_cards) */

.tp-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.tp-cards--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.tp-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px;
  border-radius: var(--tp-radius);
  background: var(--tp-surface);
}

a.tp-card {
  color: inherit;
  text-decoration: none;
}

a.tp-card:hover {
  background: var(--tp-surface-hover);
}

.tp-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  width: 40px;
  height: 40px;
  margin-bottom: 4px;
  border-radius: var(--tp-radius);
  background: var(--secondary-accent);
  color: var(--text-on-secondary-accent);
}

.tp-card__icon .tp-icon {
  width: 22px;
  height: 22px;
}

.tp-card__title {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
}

.tp-card__text {
  color: var(--tp-text-soft);
  font-size: 15px;
  line-height: 1.55;
}

/* Tool cards (tp_tool_cards) */

.tp-tools {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.tp-tool {
  display: flex;
  flex-direction: column;
  border-radius: var(--tp-radius);
  overflow: hidden;
  background: var(--tp-surface);
  color: inherit;
  text-decoration: none;
}

.tp-tool:hover {
  background: var(--tp-surface-hover);
}

.tp-tool__image {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--tp-fill);
  color: var(--tp-text-faint);
}

/* no box of its own: the <img> fills the frame */
.tp-tool__image picture {
  display: contents;
}

.tp-tool__image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.2s ease;
}

.tp-tool:hover .tp-tool__image img {
  transform: scale(1.03);
}

.tp-tool__image .tp-logo {
  width: 64px;
  height: 64px;
}

.tp-tool__body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px;
}

.tp-tool__body .tp-badges {
  margin-bottom: 4px;
}

.tp-tool__title {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
}

.tp-tool__text {
  color: var(--tp-text-soft);
  font-size: 15px;
  line-height: 1.55;
}

/* Alternating image + text rows (tp_showcase) */

.tp-showcase {
  display: flex;
  flex-direction: column;
  gap: 80px;
}

.tp-showcase__row {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  align-items: center;
  gap: 56px;
}

.tp-showcase__row--reverse .tp-media {
  order: 2;
}

.tp-showcase__title {
  font-size: clamp(22px, 2.6vw, 28px);
  font-weight: 700;
  line-height: 1.25;
}

.tp-showcase__text {
  margin-top: 12px;
  color: var(--tp-text-soft);
  font-size: 16px;
  line-height: 1.6;
}

.tp-checks {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 16px;
}

.tp-checks li {
  position: relative;
  padding-left: 26px;
}

.tp-checks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 3px;
  width: 18px;
  height: 18px;
  background: var(--secondary-accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M16.7 5.3a1 1 0 0 1 0 1.4l-8 8a1 1 0 0 1-1.4 0l-4-4a1 1 0 1 1 1.4-1.4L8 12.58l7.3-7.3a1 1 0 0 1 1.4 0Z'/%3E%3C/svg%3E")
    center / 16px no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M16.7 5.3a1 1 0 0 1 0 1.4l-8 8a1 1 0 0 1-1.4 0l-4-4a1 1 0 1 1 1.4-1.4L8 12.58l7.3-7.3a1 1 0 0 1 1.4 0Z'/%3E%3C/svg%3E")
    center / 16px no-repeat;
}

/* Numbered steps (tp_steps) */

.tp-steps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  counter-reset: tp-step;
}

.tp-step {
  display: flex;
  gap: 16px;
  padding: 20px;
  border-radius: var(--tp-radius);
  background: var(--tp-surface);
}

.tp-step::before {
  counter-increment: tp-step;
  content: counter(tp-step);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 100%;
  background: var(--primary-accent);
  color: var(--text-on-primary-accent);
  font-size: 15px;
  font-weight: 700;
}

.tp-step__title {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
  margin-top: 5px;
}

.tp-step__text {
  margin-top: 8px;
  color: var(--tp-text-soft);
  font-size: 15px;
  line-height: 1.6;
}

/* Code to copy (tp_code): a file's name and a Copy button over the code */

.tp-code {
  margin: 0;
  border: 1px solid var(--tp-divider);
  border-radius: var(--tp-radius);
  background: var(--tp-surface);
  overflow: hidden;
}

.tp-code + .tp-cards {
  margin-top: 24px;
}

.tp-card .tp-code {
  margin-top: 6px;
  background: var(--bg-color);
}

.tp-code__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 6px 6px 6px 14px;
  border-bottom: 1px solid var(--tp-divider);
}

.tp-code__label {
  color: var(--tp-text-faint);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 13px;
}

.tp-code__copy {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border: 0;
  border-radius: var(--tp-radius-pill);
  background: transparent;
  color: var(--tp-text-soft);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.tp-code__copy:hover,
.tp-code__copy:focus-visible {
  background: var(--tp-fill);
  color: var(--tp-text);
}

.tp-code__copy .tp-icon {
  width: 16px;
  height: 16px;
}

.tp-code__copy .tp-icon:nth-of-type(2),
.tp-code__copy.is-copied .tp-icon:first-of-type {
  display: none;
}

.tp-code__copy.is-copied {
  color: var(--primary-accent);
}

.tp-code__copy.is-copied .tp-icon:nth-of-type(2) {
  display: block;
}

.tp-code__pre {
  margin: 0;
  padding: 12px 14px;
  overflow-x: auto;
  font-size: 13px;
  line-height: 1.6;
}

.tp .tp-code__pre code {
  padding: 0;
  border-radius: 0;
  background: none;
  font-size: inherit;
  white-space: pre;
  overflow-wrap: normal;
}

/* in a card, long lines wrap instead of scrolling (Copy takes them as they are) */
.tp .tp-card .tp-code__pre code {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* FAQ (tp_faq): one list with dividers, like the creator's layer list */

.tp-faq {
  max-width: 780px;
  margin: 0 auto;
}

.tp-faq details {
  border-bottom: 1px solid var(--tp-divider);
}

.tp-faq details:first-child {
  border-top: 1px solid var(--tp-divider);
}

.tp-faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 8px;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  list-style: none;
}

.tp-faq summary:hover {
  background: var(--tp-surface);
}

.tp-faq summary::-webkit-details-marker {
  display: none;
}

.tp-faq summary .tp-icon {
  width: 16px;
  height: 16px;
  color: var(--tp-text-faint);
}

.tp-faq details[open] summary .tp-icon {
  transform: rotate(180deg);
}

.tp-faq__answer {
  padding: 0 8px 16px;
  color: var(--tp-text-soft);
  line-height: 1.6;
}

/* Closing panel (tp_cta) */

.tp-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 48px 32px;
  border-radius: 16px;
  background: var(--tp-surface);
  text-align: center;
}

.tp-cta .tp-lead {
  max-width: 560px;
}

/* Footer */

.tp-footer {
  padding: 48px 0 24px;
  border-top: 1px solid var(--tp-divider);
  font-size: 14px;
  line-height: 1.5;
}

/* main.css's reset, for apps without it (no specificity: the footer's own margins win) */
:where(.tp-footer) :where(h2, p, ul) {
  margin: 0;
  padding: 0;
}

:where(.tp-footer) :where(ul) {
  list-style: none;
}

.tp-footer__top {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) repeat(4, minmax(0, 1fr));
  gap: 40px;
}

.tp-footer__tagline {
  margin-top: 12px;
  max-width: 300px;
  color: var(--tp-text-soft);
  line-height: 1.55;
}

.tp-socials {
  display: flex;
  gap: 12px;
  margin-top: 16px;
}

/* .tp-footer: over the kit creator's link color in apps */
.tp-footer .tp-social {
  display: inline-flex;
  color: var(--tp-text-soft);
}

.tp-footer .tp-social:hover {
  color: var(--tp-text);
}

.tp-footer__heading {
  margin-bottom: 12px;
  color: var(--tp-text-soft);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.tp-footer__group ul {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tp-footer__group a {
  color: var(--tp-text);
  text-decoration: none;
  overflow-wrap: anywhere;
}

.tp-footer__group a:hover {
  color: var(--tp-text-soft);
}

.tp-footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 40px;
  padding-top: 16px;
  border-top: 1px solid var(--tp-divider);
  color: var(--tp-text-faint);
  font-size: 13px;
}

/* 404 (tp_not_found) */

.tp-not-found__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.tp-not-found__code {
  color: var(--secondary-accent);
  font-size: clamp(96px, 18vw, 152px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.04em;
}

.tp-not-found .tp-h2 {
  margin-top: 8px;
}

.tp-not-found .tp-lead {
  max-width: 520px;
}

.tp-not-found__links {
  width: 100%;
  margin-top: 40px;
  text-align: left;
}

/* Responsive */

@media (max-width: 1023px) {
  .tp-cards,
  .tp-tools {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tp-footer__top {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .tp-footer__brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 899px) {
  .tp .tp-header__cta {
    display: none;
  }

  .tp .tp-menu-toggle {
    display: inline-flex;
  }

  .tp-header__actions {
    margin-left: auto;
    gap: 4px;
  }

  .tp-nav {
    display: none;
    position: absolute;
    top: var(--tp-header-height);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    margin: 0;
    padding: 8px var(--tp-gutter) 16px;
    background: var(--bg-color);
    border-bottom: 1px solid var(--tp-divider);
    box-shadow: var(--shadow);
  }

  .tp-nav.is-open {
    display: flex;
  }

  .tp-nav__link {
    padding: 12px 16px;
    font-size: 16px;
  }

  .tp .tp-nav__cta {
    display: inline-flex;
    margin-top: 8px;
  }

  .tp-hero__inner,
  .tp-showcase__row {
    grid-template-columns: minmax(0, 1fr);
    gap: 40px;
  }

  .tp-showcase__row--reverse .tp-media {
    order: 0;
  }

  .tp-showcase {
    gap: 64px;
  }

  .tp-steps {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 639px) {
  .tp,
  .tp-footer {
    --tp-gutter: 16px;
  }

  .tp-section {
    padding: 56px 0;
  }

  .tp-section--cta {
    padding-top: 0;
  }

  .tp-hero {
    padding: 40px 0 56px;
  }

  /* after .tp-cards--2, so it wins */
  .tp-cards,
  .tp-tools {
    grid-template-columns: minmax(0, 1fr);
  }

  .tp-breadcrumbs {
    padding-top: 16px;
  }

  .tp-breadcrumbs ~ .tp-hero {
    padding-top: 24px;
  }

  .tp-footer__top {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px;
  }

  .tp-footer__bottom {
    flex-direction: column;
    align-items: flex-start;
  }

  .tp-actions .button-lg {
    flex: 1 1 100%;
  }

  .tp-cta {
    padding: 40px 16px;
  }
}
