/* ============================================================================
   SPF Client-First — global.css (the class layer)
   Base element styles, page structure and the Client-First utility classes.
   Every value reads a token from tokens.css or theme.css.
   Order: base -> structure -> spacing -> type -> color -> layout -> buttons ->
   visibility -> state. Direction classes use !important, as Client-First does,
   so `margin-top margin-medium` works regardless of source order.
   ============================================================================ */

/* ---- base ------------------------------------------------------------------ */
*,
:is(*)::before,
:is(*)::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font--body);
  font-size: var(--text-size--regular);
  font-weight: var(--font-weight--body);
  line-height: var(--line-height--body);
  color: var(--color--text-primary);
  background-color: var(--color--background-primary);
}

h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  margin-bottom: 0;
  font-family: var(--font--heading);
  font-weight: var(--font-weight--heading);
  line-height: var(--line-height--heading);
  letter-spacing: var(--letter-spacing--heading);
  text-transform: var(--text-transform--heading);
  overflow-wrap: break-word;
}
h1, h2, h3 {
  text-wrap: balance;
}
/* the recipe's three heading sizes (AGENTS "One voice"): components never set a heading's size */
h1 { font-size: var(--type--page); }
h2 { font-size: var(--type--section); }
h3, h4, h5, h6 { font-size: var(--type--item); }

/* the section heading recipe: an optional short rule under every section heading, in the accent
   (recipe palette role heading-rule) or the ink; theme build sets --heading--rule to "" or none */
main :is(h2)::after {
  content: var(--heading--rule);
  display: block;
  width: var(--heading--rule-width);
  max-width: 100%;
  height: var(--border-width--strong);
  margin-top: var(--space--small);
  background-color: var(--heading--rule-color);
}

p, blockquote, figure, dl, dd {
  margin-top: 0;
  margin-bottom: 0;
}

p {
  text-wrap: pretty;
}

ul, ol {
  margin-top: 0;
  margin-bottom: 0;
  padding-left: var(--space--medium);
}

a {
  color: inherit;
  text-underline-offset: var(--space--xxsmall);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
  vertical-align: middle;
}

svg {
  display: block;
}

button,
input,
select,
textarea {
  font-family: inherit;
  font-size: var(--text-size--small);
  line-height: inherit;
  color: inherit;
}

:focus-visible {
  outline: var(--border-width--strong) solid var(--color--focus);
  outline-offset: var(--space--xxsmall);
}

[hidden] {
  display: none !important;
}

/* ---- structure ---------------------------------------------------------------- */
.page-wrapper {
  display: block;
}

.main-wrapper {
  display: block;
}

.padding-global {
  padding-left: var(--site--margin);
  padding-right: var(--site--margin);
}

.container-small {
  width: 100%;
  max-width: var(--container--small);
  margin-left: auto;
  margin-right: auto;
}

.container-medium {
  width: 100%;
  max-width: var(--container--medium);
  margin-left: auto;
  margin-right: auto;
}

.container-large {
  width: 100%;
  max-width: var(--container--large);
  margin-left: auto;
  margin-right: auto;
}

.padding-section-small {
  padding-top: var(--padding-section--small);
  padding-bottom: var(--padding-section--small);
}

.padding-section-medium {
  padding-top: var(--padding-section--medium);
  padding-bottom: var(--padding-section--medium);
}

.padding-section-large {
  padding-top: var(--padding-section--large);
  padding-bottom: var(--padding-section--large);
}

/* section-header: the heading on the left (7 parts) and its intro on the right (5 parts),
   bottoms aligned, from 991px up; stacked below. Put it at the top of a section in place
   of a centered heading over the content. section-header_intro takes the lead paragraph
   and, if any, the section's one action. */
.section-header {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  align-items: end;
  column-gap: var(--space--xlarge);
  row-gap: var(--space--small);
}

.section-header_heading {
  min-width: 0;
}

.section-header_intro {
  display: grid;
  justify-items: start;
  gap: var(--space--small);
  max-width: var(--max-width--medium);
  color: var(--color--text-secondary);
}

/* motif-rule: a plain hairline rule (since 2026-10-13 it carries no motif mark: a mark sitting on
   a line read as a rendering slip, T22). The class stays so pages that use it keep their rule.
   motif-mark: the theme's mark as one deliberate sign, at most once or twice a page where it
   composes (motif restraint, AGENTS "Design"); never a list bullet, a rule end or a card corner. */
.motif-rule {
  position: relative;
  border-top: var(--border-width--hairline) solid var(--color--border-primary);
}

.motif-mark {
  display: var(--motif--mark-display);
  flex: none;
  width: var(--space--small);
  height: var(--space--small);
  background-color: var(--motif--color);
  clip-path: var(--motif--mark);
}

/* ---- spacing: margin-*, padding-*, spacer-* -------------------------------------- */
.margin-0 {
  margin: 0;
}

.padding-0 {
  padding: 0;
}

.margin-tiny {
  margin: var(--space--tiny);
}

.margin-xxsmall {
  margin: var(--space--xxsmall);
}

.margin-xsmall {
  margin: var(--space--xsmall);
}

.margin-small {
  margin: var(--space--small);
}

.margin-medium {
  margin: var(--space--medium);
}

.margin-large {
  margin: var(--space--large);
}

.margin-xlarge {
  margin: var(--space--xlarge);
}

.margin-xxlarge {
  margin: var(--space--xxlarge);
}

.margin-huge {
  margin: var(--space--huge);
}

.margin-xhuge {
  margin: var(--space--xhuge);
}

.margin-xxhuge {
  margin: var(--space--xxhuge);
}

.padding-tiny {
  padding: var(--space--tiny);
}

.padding-xxsmall {
  padding: var(--space--xxsmall);
}

.padding-xsmall {
  padding: var(--space--xsmall);
}

.padding-small {
  padding: var(--space--small);
}

.padding-medium {
  padding: var(--space--medium);
}

.padding-large {
  padding: var(--space--large);
}

.padding-xlarge {
  padding: var(--space--xlarge);
}

.padding-xxlarge {
  padding: var(--space--xxlarge);
}

.padding-huge {
  padding: var(--space--huge);
}

.padding-xhuge {
  padding: var(--space--xhuge);
}

.padding-xxhuge {
  padding: var(--space--xxhuge);
}

.spacer-tiny {
  width: 100%;
  padding-top: var(--space--tiny);
}

.spacer-xxsmall {
  width: 100%;
  padding-top: var(--space--xxsmall);
}

.spacer-xsmall {
  width: 100%;
  padding-top: var(--space--xsmall);
}

.spacer-small {
  width: 100%;
  padding-top: var(--space--small);
}

.spacer-medium {
  width: 100%;
  padding-top: var(--space--medium);
}

.spacer-large {
  width: 100%;
  padding-top: var(--space--large);
}

.spacer-xlarge {
  width: 100%;
  padding-top: var(--space--xlarge);
}

.spacer-xxlarge {
  width: 100%;
  padding-top: var(--space--xxlarge);
}

.spacer-huge {
  width: 100%;
  padding-top: var(--space--huge);
}

.spacer-xhuge {
  width: 100%;
  padding-top: var(--space--xhuge);
}

.spacer-xxhuge {
  width: 100%;
  padding-top: var(--space--xxhuge);
}

.margin-top {
  margin-right: 0 !important;
  margin-bottom: 0 !important;
  margin-left: 0 !important;
}

.margin-bottom {
  margin-top: 0 !important;
  margin-right: 0 !important;
  margin-left: 0 !important;
}

.margin-left {
  margin-top: 0 !important;
  margin-right: 0 !important;
  margin-bottom: 0 !important;
}

.margin-right {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  margin-left: 0 !important;
}

.margin-vertical {
  margin-right: 0 !important;
  margin-left: 0 !important;
}

.margin-horizontal {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

.padding-top {
  padding-right: 0 !important;
  padding-bottom: 0 !important;
  padding-left: 0 !important;
}

.padding-bottom {
  padding-top: 0 !important;
  padding-right: 0 !important;
  padding-left: 0 !important;
}

.padding-left {
  padding-top: 0 !important;
  padding-right: 0 !important;
  padding-bottom: 0 !important;
}

.padding-right {
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  padding-left: 0 !important;
}

.padding-vertical {
  padding-right: 0 !important;
  padding-left: 0 !important;
}

.padding-horizontal {
  padding-top: 0 !important;
  padding-bottom: 0 !important;
}

/* ---- type ------------------------------------------------------------------------- */
.heading-style-h1 {
  text-wrap: balance;
  font-family: var(--font--heading);
  font-size: var(--heading-style--h1);
  font-weight: var(--font-weight--heading);
  line-height: var(--line-height--heading);
  letter-spacing: var(--letter-spacing--heading);
  text-transform: var(--text-transform--heading);
}

.heading-style-h2 {
  text-wrap: balance;
  font-family: var(--font--heading);
  font-size: var(--heading-style--h2);
  font-weight: var(--font-weight--heading);
  line-height: var(--line-height--heading);
  letter-spacing: var(--letter-spacing--heading);
  text-transform: var(--text-transform--heading);
}

.heading-style-h3 {
  text-wrap: balance;
  font-family: var(--font--heading);
  font-size: var(--heading-style--h3);
  font-weight: var(--font-weight--heading);
  line-height: var(--line-height--heading);
  letter-spacing: var(--letter-spacing--heading);
  text-transform: var(--text-transform--heading);
}

.heading-style-h4 {
  font-family: var(--font--heading);
  font-size: var(--heading-style--h4);
  font-weight: var(--font-weight--heading);
  line-height: var(--line-height--heading);
  letter-spacing: var(--letter-spacing--heading);
  text-transform: var(--text-transform--heading);
}

.heading-style-h5 {
  font-family: var(--font--heading);
  font-size: var(--heading-style--h5);
  font-weight: var(--font-weight--heading);
  line-height: var(--line-height--heading);
  letter-spacing: var(--letter-spacing--heading);
  text-transform: var(--text-transform--heading);
}

.heading-style-h6 {
  font-family: var(--font--heading);
  font-size: var(--heading-style--h6);
  font-weight: var(--font-weight--heading);
  line-height: var(--line-height--heading);
  letter-spacing: var(--letter-spacing--heading);
  text-transform: var(--text-transform--heading);
}

.text-size-large {
  font-size: var(--text-size--large);
}

.text-size-medium {
  font-size: var(--text-size--medium);
}

.text-size-regular {
  font-size: var(--text-size--regular);
}

.text-size-small {
  font-size: var(--text-size--small);
}

.text-weight-xbold {
  font-weight: var(--font-weight--xbold);
}

.text-weight-bold {
  font-weight: var(--font-weight--bold);
}

.text-weight-semibold {
  font-weight: var(--font-weight--semibold);
}

.text-weight-medium {
  font-weight: var(--font-weight--medium);
}

.text-weight-normal {
  font-weight: var(--font-weight--normal);
}

.text-weight-light {
  font-weight: var(--font-weight--light);
}

.text-align-left {
  text-align: left;
}

.text-align-center {
  text-align: center;
}

.text-align-right {
  text-align: right;
}

.text-style-allcaps {
  text-transform: uppercase;
  letter-spacing: var(--letter-spacing--allcaps);
}

.text-style-italic {
  font-style: italic;
}

.text-style-link {
  color: var(--color--link);
  text-decoration: underline;
  text-decoration-thickness: var(--border-width--hairline);
  text-underline-offset: var(--space--tiny);
  text-decoration-skip-ink: auto;
  transition: text-decoration-thickness var(--motion--duration-fast) var(--motion--ease);
}

.text-style-link:hover {
  text-decoration-thickness: var(--border-width--strong);
}

.text-style-link:active {
  color: var(--color--text-primary);
}

.text-style-muted {
  color: var(--color--text-secondary);
}

.text-style-nowrap {
  white-space: nowrap;
}

.text-style-strikethrough {
  text-decoration: line-through;
}

.text-style-quote {
  margin: 0;
  padding-left: var(--space--medium);
  border-left: var(--border-width--hairline) solid var(--color--border-primary);
  font-size: var(--text-size--medium);
  line-height: var(--line-height--body);
}

.text-style-2lines {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.text-style-3lines {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.text-rich-text :is(h2, h3, h4, h5, h6) {
  margin-top: var(--space--medium);
  margin-bottom: var(--space--small);
}

.text-rich-text :is(p, ul, ol, blockquote) {
  margin-bottom: var(--space--small);
}

.text-rich-text :is(a) {
  color: var(--color--link);
}

/* ---- section schemes (SPEC 5e, "Page composition") -------------------------------
   A section's ground is its scheme, set on the section root by `spf-site add --scheme`:
   light (the page ground), alt (the second ground), dark (the inverse ground) and accent (the
   accent as a ground; only when the recipe's palette gives the accent the role "ground"). Inside a
   scheme the colour tokens are remapped (css/tokens.css, "section schemes"), so every class and
   component that reads them follows; this rule paints the section with its scheme's ground. */
[data-scheme] {
  background-color: var(--color--background-primary);
  color: var(--color--text-primary);
}

/* ---- color ------------------------------------------------------------------------ */
.text-color-primary {
  color: var(--color--text-primary);
}

.text-color-secondary {
  color: var(--color--text-secondary);
}

.text-color-alternate {
  color: var(--color--text-alternate);
}

.text-color-accent {
  color: var(--color--text-accent);
}

.background-color-primary {
  background-color: var(--color--background-primary);
}

.background-color-secondary {
  background-color: var(--color--background-secondary);
}

.background-color-tertiary {
  background-color: var(--color--background-tertiary);
}

.background-color-alternate {
  background-color: var(--color--background-alternate);
  color: var(--color--text-alternate);
}

/* ---- layout helpers -------------------------------------------------------------- */
.max-width-full {
  width: 100%;
  max-width: none;
}

.max-width-xxsmall {
  width: 100%;
  max-width: var(--max-width--xxsmall);
}

.max-width-xsmall {
  width: 100%;
  max-width: var(--max-width--xsmall);
}

.max-width-small {
  width: 100%;
  max-width: var(--max-width--small);
}

.max-width-medium {
  width: 100%;
  max-width: var(--max-width--medium);
}

.max-width-large {
  width: 100%;
  max-width: var(--max-width--large);
}

.max-width-xlarge {
  width: 100%;
  max-width: var(--max-width--xlarge);
}

.max-width-xxlarge {
  width: 100%;
  max-width: var(--max-width--xxlarge);
}

.align-center {
  margin-left: auto;
  margin-right: auto;
}

.overflow-hidden {
  overflow: hidden;
}

.overflow-scroll {
  overflow: scroll;
}

.overflow-auto {
  overflow: auto;
}

.overflow-visible {
  overflow: visible;
}

.layer {
  position: absolute;
  inset: 0;
}

.pointer-events-none {
  pointer-events: none;
}

.pointer-events-auto {
  pointer-events: auto;
}

.z-index-1 {
  position: relative;
  z-index: 1;
}

.z-index-2 {
  position: relative;
  z-index: 2;
}

.icon-height-small {
  height: var(--size--icon-small);
}

.icon-height-medium {
  height: var(--size--icon-medium);
}

.icon-height-large {
  height: var(--size--icon-large);
}

.icon-1x1-small {
  width: var(--size--icon-small);
  height: var(--size--icon-small);
}

.icon-1x1-medium {
  width: var(--size--icon-medium);
  height: var(--size--icon-medium);
}

.icon-1x1-large {
  width: var(--size--icon-large);
  height: var(--size--icon-large);
}

/* ---- buttons ------------------------------------------------------------------------ */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space--xsmall);
  min-height: var(--size--tap);
  padding: var(--space--xsmall) var(--space--medium);
  border: var(--border-width--hairline) solid var(--color--accent);
  border-radius: var(--radius--button);
  background-color: var(--color--accent);
  color: var(--color--accent-contrast);
  font-family: var(--font--body);
  font-size: var(--text-size--small);
  font-weight: var(--font-weight--semibold);
  line-height: var(--line-height--tight);
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--motion--duration-fast) var(--motion--ease), color var(--motion--duration-fast) var(--motion--ease), border-color var(--motion--duration-fast) var(--motion--ease), transform var(--motion--duration-fast) var(--motion--ease);
}

.button:hover {
  border-color: var(--color--accent-hover);
  background-color: var(--color--accent-hover);
}

.button:active {
  transform: translateY(var(--border-width--hairline));
}

/* disabled keeps the button's own shape and fill, faded: a dashed or emptied outline reads as
   broken, not as "not now" (goal 16, the reviews-carousel arrow) */
.button:disabled,
.button[aria-disabled="true"] {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
  pointer-events: none;
}

/* the secondary style is the recipe's (recipe.buttons.secondary): text or outline */
.button.is-secondary {
  padding-left: var(--button--secondary-padding);
  padding-right: var(--button--secondary-padding);
  border-color: var(--button--secondary-border);
  background-color: transparent;
  color: inherit;
  text-decoration: var(--button--secondary-decoration);
}

.button.is-secondary:hover {
  border-color: var(--button--secondary-hover-border);
  background-color: var(--button--secondary-hover-background);
  color: var(--button--secondary-hover-color);
}

.button.is-alternate {
  border-color: var(--color--background-primary);
  background-color: var(--color--background-primary);
  color: var(--color--text-primary);
}

.button.is-alternate:hover {
  border-color: var(--color--background-secondary);
  background-color: var(--color--background-secondary);
}

.button.is-small {
  padding: var(--space--xxsmall) var(--space--small);
}

.button.is-large {
  padding: var(--space--small) var(--space--large);
  font-size: var(--text-size--regular);
}

.button.is-text {
  padding-left: 0;
  padding-right: 0;
  border-color: transparent;
  background-color: transparent;
  color: inherit;
  text-decoration: underline;
}

.button.is-text:hover {
  border-color: transparent;
  background-color: transparent;
  color: var(--color--text-accent);
}

.button.is-icon {
  padding-left: var(--space--small);
  padding-right: var(--space--small);
}

/* a trailing arrow (an svg after the label) that steps forward on hover and focus */
.button.is-arrow svg {
  width: var(--size--icon-small);
  height: var(--size--icon-small);
  transition: transform var(--motion--duration-fast) var(--motion--ease);
}

.button.is-arrow:hover svg,
.button.is-arrow:focus-visible svg {
  transform: translateX(var(--space--xxsmall));
}

/* ---- the hover set (goal 16): one way for every card, tile and row that is a link to answer
   the pointer. .hover-card on the link: its .hover-card_image zooms a little inside its frame,
   its .hover-card_title takes the accent underline, its .hover-card_arrow steps forward; the
   focus ring is drawn on the whole link. Nothing changes size or layout, and reduced motion
   keeps the colour and underline changes only. */
.hover-card {
  color: inherit;
  text-decoration: none;
}

.hover-card_frame {
  overflow: hidden;
}

.hover-card_image {
  transition: transform var(--motion--duration-slow) var(--motion--ease);
}

.hover-card:hover .hover-card_image,
.hover-card:focus-visible .hover-card_image {
  transform: scale(1.04);
}

.hover-card_title {
  text-decoration: underline;
  text-decoration-color: transparent;
  text-decoration-thickness: var(--border-width--strong);
  text-underline-offset: var(--space--xxsmall);
  transition: text-decoration-color var(--motion--duration-fast) var(--motion--ease);
}

.hover-card:hover .hover-card_title,
.hover-card:focus-visible .hover-card_title {
  text-decoration-color: var(--color--link);
}

.hover-card_arrow {
  flex: none;
  width: var(--size--icon-small);
  height: var(--size--icon-small);
  color: var(--color--link);
  transition: transform var(--motion--duration-fast) var(--motion--ease);
}

.hover-card:hover .hover-card_arrow,
.hover-card:focus-visible .hover-card_arrow {
  transform: translateX(var(--space--xxsmall));
}

.hover-card:focus-visible {
  outline: var(--border-width--strong) solid var(--color--focus);
  outline-offset: var(--space--xxsmall);
}

.button-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space--small);
}

/* the current page in any navigation */
a[aria-current="page"] {
  text-decoration: underline;
  text-decoration-thickness: var(--border-width--strong);
  text-underline-offset: var(--space--xsmall);
}

/* the pause control spf.js adds after anything that moves on its own for more than five
   seconds (marquees, looping type, self-drawing trails) */
/* left-aligned: every theme motif cuts the bottom-right corner of a band */
.spf-pause-bar {
  display: flex;
  justify-content: flex-start;
}

.spf-pause {
  display: inline-flex;
  align-items: center;
  gap: var(--space--xsmall);
  min-height: var(--size--tap);
  margin-top: var(--space--xsmall);
  padding: var(--space--xxsmall) var(--space--small);
  border: var(--border-width--hairline) solid currentColor;
  border-radius: var(--radius--button);
  background-color: transparent;
  color: inherit;
  font-size: var(--text-size--small);
  font-weight: var(--font-weight--semibold);
  line-height: var(--line-height--tight);
  cursor: pointer;
}

.spf-pause:hover {
  background-color: var(--color--background-secondary);
  color: var(--color--text-primary);
}

.spf-pause svg {
  width: var(--size--icon-small);
  height: var(--size--icon-small);
}

:is(.is-paused),
:is(.is-paused) * {
  animation-play-state: paused !important;
}

/* the one entrance every overlay uses (modal, menu panel, dropdown, lightbox): a fade with
   a short rise. Reduced motion cuts it to nothing (the block below). */
@keyframes spf-enter {
  from {
    opacity: 0;
    transform: translateY(var(--space--small));
  }
}

@keyframes spf-fade {
  from {
    opacity: 0;
  }
}

/* ---- visibility -------------------------------------------------------------------- */
.hide {
  display: none;
}

/* The skip link (SPEC 7a): the first thing in .page-wrapper, pointing at <main id="main">.
   A full-size button kept above the top edge until it has keyboard focus, then shown over
   everything (above the navbar and any overlay). */
.skip-link {
  position: absolute;
  top: var(--space--small);
  left: var(--space--small);
  z-index: 500;
  display: inline-flex;
  align-items: center;
  min-height: var(--size--tap);
  padding: var(--space--xsmall) var(--space--small);
  border-radius: var(--radius--button);
  background-color: var(--color--accent);
  color: var(--color--accent-contrast);
  font-family: var(--font--body);
  font-size: var(--text-size--small);
  font-weight: var(--font-weight--semibold);
  text-decoration: none;
  transform: translateY(-300%);
}

.skip-link:focus {
  transform: none;
}

/* ---- JS state ------------------------------------------------------------------------
   html.js is set by js/spf.js before first paint. Anything hidden at start is hidden
   only under html.js, so pages stay readable with JS off. Written as :is() compounds
   so Instatic's publish tree-shaker keeps them. */
/* data-spf-cloak       hidden under html.js at every width until .is-open
   data-spf-cloak="tablet"  hidden under html.js at 991px and below (mobile menus) */
:is(html.js) :is([data-spf-cloak=""]:not(.is-open)) {
  display: none;
}

/* ---- Smooth scroll (Lenis, js/vendor/lenis.min.js; 2026-10-28) ------------------------
   spf.js adds .lenis to <html> only when it starts Lenis (html[data-spf-smooth], the script
   loaded, motion allowed). These are the rules from the package's dist/lenis.css, kept here
   because vendor.json only loads scripts. Nothing applies with JS off or under reduced motion. */
:is(html.lenis), :is(html.lenis) body {
  height: auto;
}
:is(.lenis:not(.lenis-autoToggle).lenis-stopped) {
  overflow: clip;
}
:is(.lenis) :is([data-lenis-prevent], [data-lenis-prevent-wheel], [data-lenis-prevent-touch], [data-lenis-prevent-vertical], [data-lenis-prevent-horizontal]) {
  overscroll-behavior: contain;
}
:is(.lenis.lenis-smooth) iframe {
  pointer-events: none;
}
:is(.lenis.lenis-autoToggle) {
  transition-property: overflow;
  transition-duration: 1ms;
  transition-behavior: allow-discrete;
}

/* a page-start loader shows once per browser session: spf.js marks html is-loader-seen in
   <head> (before the first frame) when the visitor has seen it or asked for reduced motion,
   so it never paints on later pages. data-spf-loader-always opts one out. */
:is(html.is-loader-seen) :is([data-spf-loader], [data-spf-scene="loader"]):not([data-spf-loader-always]) {
  display: none !important;
}

[x-cloak],
[v-cloak] {
  display: none !important;
}

/* data-spf-js-only     controls that do nothing without JS (filter buttons, compare
   handles), and data-spf-filter-controls: not shown when JS is off, so the JS-off page shows every item instead. */
:is(html:not(.js)) :is([data-spf-js-only], [data-spf-filter-controls]) {
  display: none;
}

/* Text split by spf.js (data-spf-split): the whole text stays in a visually hidden copy
   for screen readers; the pieces are aria-hidden. Lines clip with clip-path (not
   overflow) so a mask reveal can slide each line in from below its own box. */
[data-spf-sr] {
  position: absolute;
  width: var(--border-width--hairline);
  height: var(--border-width--hairline);
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

:is([data-spf-piece="word"], [data-spf-piece="char"]) {
  display: inline-block;
}

[data-spf-piece="line"] {
  display: block;
  clip-path: inset(-25% -5% -25% -5%);
}

[data-spf-piece="line-inner"] {
  display: block;
}

/* data-spf-reveal="" | fade | rise | scale | mask   scroll reveals (tier 2). Hidden only
   under html.js and only when motion is allowed; spf.js adds .is-inview when the element
   scrolls into view. A data-spf-reveal-group parent sets --spf-i on each for a stagger.
   The house entrance (one motion system, goal 16) is the bare attribute: a short rise with a
   fade, staggered by its group; fade, scale and mask stay for the entries that already use
   them. */
@media (prefers-reduced-motion: no-preference) {
  :is(html.js) :is([data-spf-reveal]) {
    transition: opacity var(--motion--duration-slow) var(--motion--ease), transform var(--motion--duration-slow) var(--motion--ease), clip-path var(--motion--duration-slow) var(--motion--ease);
    transition-delay: calc(var(--spf-i, 0) * var(--motion--stagger, 80ms));
  }

  :is(html.js) :is([data-spf-reveal]:not(.is-inview)) {
    opacity: 0;
  }

  :is(html.js) :is([data-spf-reveal=""]:not(.is-inview), [data-spf-reveal="rise"]:not(.is-inview)) {
    transform: translateY(var(--space--medium));
  }

  :is(html.js) :is([data-spf-reveal="scale"]:not(.is-inview)) {
    transform: scale(0.94);
  }

  :is(html.js) :is([data-spf-reveal="mask"]:not(.is-inview)) {
    opacity: 1;
    clip-path: inset(0 0 100% 0);
  }

  /* inset() to inset() so the mask interpolates; a mask reveal owns its element's
     clip-path, so put a motif clip on a child, not on the masked element. */
  :is(html.js) :is([data-spf-reveal="mask"].is-inview) {
    clip-path: inset(0 0 0 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  :is(*)::before,
  :is(*)::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---- breakpoints ------------------------------------------------------------------- */
@media (max-width: 991px) {
  .section-header {
    grid-template-columns: minmax(0, 1fr);
  }

  :is(html.js) :is([data-spf-cloak="tablet"]:not(.is-open)) {
    display: none;
  }

  .max-width-full-tablet {
    width: 100%;
    max-width: none;
  }

  .hide-tablet {
    display: none;
  }
}

@media (max-width: 767px) {
  .max-width-full-mobile-landscape {
    width: 100%;
    max-width: none;
  }

  .hide-mobile-landscape {
    display: none;
  }
}

@media (max-width: 479px) {
  .button-group {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    justify-items: stretch;
  }

  .button-group > .button {
    width: 100%;
  }

  .button-group > .button.is-text {
    width: auto;
    justify-self: start;
  }

  .max-width-full-mobile-portrait {
    width: 100%;
    max-width: none;
  }

  .hide-mobile-portrait {
    display: none;
  }
}
