@media (max-width: 782px) {
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-group.is-style-rangee-adaptative.is-layout-flex:not(.is-vertical) {
    flex-wrap: wrap;
    justify-content: center;
  }
}

/* Separator catalog: tokenized strokes, shared by front and editor. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator {
  position: relative;
  box-sizing: border-box;
  border: 0;
  min-height: 0 !important;
  max-width: 100%;
  --pl-separator-primary: var(--pl-border-strong);
  --pl-separator-secondary: var(--pl-border-subtle);
  --pl-separator-fill: var(--pl-border-subtle);
  background-color: transparent;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background.is-style-accent,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background.is-style-trait-fin,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background:is(
  .is-style-organique-doux,
  .is-style-organique-vivant,
  .is-style-organique-brut
) {
  background-color: inherit;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background.is-style-asymetrique,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background.is-style-rupture,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background.is-style-double-trait {
  background-color: inherit;
  -webkit-mask-image: linear-gradient(
    to right,
    #000 0 100%
  );
  mask-image: linear-gradient(to right, #000 0 100%);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background.is-style-asymetrique {
  -webkit-mask-image: linear-gradient(to right, #000 0 22%, transparent 22% 24%, #000 24% 100%);
  mask-image: linear-gradient(to right, #000 0 22%, transparent 22% 24%, #000 24% 100%);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background.is-style-rupture {
  -webkit-mask-image: linear-gradient(to right, #000 0 calc(50% - 3rem), transparent calc(50% - 3rem) calc(50% + 3rem), #000 calc(50% + 3rem) 100%);
  mask-image: linear-gradient(to right, #000 0 calc(50% - 3rem), transparent calc(50% - 3rem) calc(50% + 3rem), #000 calc(50% + 3rem) 100%);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background.is-style-double-trait {
  -webkit-mask-image: linear-gradient(to bottom, #000 0 1px, transparent 1px calc(100% - 1px), #000 calc(100% - 1px) 100%);
  mask-image: linear-gradient(to bottom, #000 0 1px, transparent 1px calc(100% - 1px), #000 calc(100% - 1px) 100%);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.is-style-accent {
  height: 3px;
  width: min(9rem, 100%);
  margin-left: 0;
  margin-right: auto;
  background-color: var(--pl-separator-fill);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.is-style-trait-fin {
  height: 2px;
  width: 100%;
  background-color: var(--pl-separator-fill);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.is-style-asymetrique {
  height: 3px;
  width: 100%;
  background: linear-gradient(
    to right,
    var(--pl-separator-primary) 0 22%,
    transparent 22% 24%,
    var(--pl-separator-secondary) 24% 100%
  );
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.is-style-rupture {
  height: 2px;
  width: 100%;
  background: linear-gradient(
    to right,
    var(--pl-separator-fill) 0 calc(50% - 3rem),
    transparent calc(50% - 3rem) calc(50% + 3rem),
    var(--pl-separator-fill) calc(50% + 3rem) 100%
  );
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.is-style-double-trait {
  height: 5px;
  width: 100%;
  background: linear-gradient(
    to bottom,
    var(--pl-separator-fill) 0 1px,
    transparent 1px calc(100% - 1px),
    var(--pl-separator-fill) calc(100% - 1px) 100%
  );
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background.is-style-asymetrique,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background.is-style-rupture,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator.has-background.is-style-double-trait {
  background: inherit;
}

/* Organic curves use fixed SVG geometry and an independent stroke width. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator:is(
  .is-style-organique-doux,
  .is-style-organique-vivant,
  .is-style-organique-brut
) {
  min-height: 32px !important;
  height: 32px;
  background-color: transparent !important;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-separator:is(
  .is-style-organique-doux,
  .is-style-organique-vivant,
  .is-style-organique-brut
)::before {
  content: none;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .pl-organic-separator__svg {
  display: block;
  width: 100%;
  height: 32px;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .pl-organic-separator-editor-overlay {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 32px;
  transform: translateY(-50%);
  pointer-events: none;
  z-index: 1;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .pl-organic-separator-editor-shell {
  position: relative;
  width: 100%;
  max-width: 100%;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .pl-organic-separator-editor-overlay .pl-organic-separator__svg {
  height: 32px;
}

/* Verre dépoli: container-only blur, with Gutenberg backgrounds preserved. */
:is(.wp-site-blocks, .editor-styles-wrapper) :is(
  .wp-block-group.is-style-verre-depoli,
  .wp-block-columns.is-style-verre-depoli,
  .wp-block-column.is-style-verre-depoli
) {
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
}

:is(.wp-site-blocks, .editor-styles-wrapper) :is(
  .wp-block-group.is-style-verre-depoli,
  .wp-block-columns.is-style-verre-depoli,
  .wp-block-column.is-style-verre-depoli
):not(.has-background) {
  background-color: color-mix(in srgb, var(--pl-bg-surface) 50%, transparent);
}

:is(.wp-site-blocks, .editor-styles-wrapper) :is(
  .is-style-surface,
  .is-style-soft,
  .is-style-outline,
  .is-style-accent,
  .is-style-card,
  .is-style-info,
  .is-style-success,
  .is-style-warning,
  .is-style-danger
) blockquote {
  margin: 0;
}

/* Surface */
:is(.wp-site-blocks, .editor-styles-wrapper) .is-style-surface:not(.wp-block-button),
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-cover.is-style-surface .wp-block-cover__inner-container {
  background: var(--pl-bg-surface);
  border: 1px solid var(--pl-border-subtle);
  border-radius: var(--pl-radius-md);
  color: var(--pl-text-primary);
  padding: var(--pl-space-md);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-surface .wp-block-button__link {
  background: var(--pl-bg-surface);
  border: 1px solid var(--pl-border-subtle);
  border-radius: var(--pl-radius-md);
  color: var(--pl-text-primary);
}

/* Soft */
:is(.wp-site-blocks, .editor-styles-wrapper) .is-style-soft:not(.wp-block-button),
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-cover.is-style-soft .wp-block-cover__inner-container {
  background: var(--pl-bg-muted);
  border: 1px solid var(--pl-border-subtle);
  border-radius: var(--pl-radius-md);
  color: var(--pl-text-primary);
  padding: var(--pl-space-md);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-soft .wp-block-button__link {
  background: var(--pl-bg-muted);
  border: 1px solid var(--pl-border-subtle);
  border-radius: var(--pl-radius-md);
  color: var(--pl-text-primary);
}

/* Outline */
:is(.wp-site-blocks, .editor-styles-wrapper) .is-style-outline:not(.wp-block-button),
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-cover.is-style-outline .wp-block-cover__inner-container {
  background: transparent !important;
  border: 1px solid var(--pl-border-strong);
  border-radius: var(--pl-radius-md);
  color: var(--pl-text-primary);
  padding: var(--pl-space-md);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-outline .wp-block-button__link {
  background: transparent;
  border: 1px solid var(--pl-border-strong);
  border-radius: var(--pl-radius-md);
  color: var(--pl-text-primary);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-outline .wp-block-button__link:is(.is-pl-touch-visible, .is-pl-touch-active),
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-outline .wp-block-button__link:hover,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-outline .wp-block-button__link:focus-visible {
  background: var(--pl-accent-hover);
  border-color: var(--pl-accent-hover);
  color: var(--pl-color-neutral-0);
}

/* Accent */
:is(.wp-site-blocks, .editor-styles-wrapper) .is-style-accent:not(.wp-block-button),
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-cover.is-style-accent .wp-block-cover__inner-container {
  background: var(--pl-accent-soft);
  border: 1px solid var(--pl-accent);
  border-left: 4px solid var(--pl-accent-strong);
  border-radius: var(--pl-radius-md);
  color: var(--pl-text-primary);
  padding: var(--pl-space-md);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-accent .wp-block-button__link {
  background: var(--pl-accent);
  border: 1px solid var(--pl-accent-strong);
  border-radius: var(--pl-radius-md);
  color: var(--pl-bg-canvas);
}

/* Card */
:is(.wp-site-blocks, .editor-styles-wrapper) .is-style-card:not(.wp-block-button),
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-cover.is-style-card .wp-block-cover__inner-container {
  background: var(--pl-bg-surface);
  border: 1px solid var(--pl-border-subtle);
  border-radius: var(--pl-radius-lg);
  box-shadow: var(--pl-shadow-sm);
  color: var(--pl-text-primary);
  padding: var(--pl-space-lg);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-card .wp-block-button__link {
  background: var(--pl-bg-surface);
  border: 1px solid var(--pl-border-subtle);
  border-radius: var(--pl-radius-lg);
  box-shadow: var(--pl-shadow-sm);
  color: var(--pl-text-primary);
}

/* Semantic variants */
:is(.wp-site-blocks, .editor-styles-wrapper) .is-style-info:not(.wp-block-button),
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-cover.is-style-info .wp-block-cover__inner-container {
  background: color-mix(in srgb, var(--pl-status-info) 14%, var(--pl-bg-canvas));
  border: 1px solid var(--pl-status-info);
  border-radius: var(--pl-radius-md);
  color: var(--pl-text-primary);
  padding: var(--pl-space-md);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-info .wp-block-button__link {
  background: var(--pl-status-info);
  border: 1px solid var(--pl-status-info);
  border-radius: var(--pl-radius-md);
  color: var(--pl-bg-canvas);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .is-style-success:not(.wp-block-button),
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-cover.is-style-success .wp-block-cover__inner-container {
  background: color-mix(in srgb, var(--pl-status-success) 14%, var(--pl-bg-canvas));
  border: 1px solid var(--pl-status-success);
  border-radius: var(--pl-radius-md);
  color: var(--pl-text-primary);
  padding: var(--pl-space-md);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-success .wp-block-button__link {
  background: var(--pl-status-success);
  border: 1px solid var(--pl-status-success);
  border-radius: var(--pl-radius-md);
  color: var(--pl-bg-canvas);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .is-style-warning:not(.wp-block-button),
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-cover.is-style-warning .wp-block-cover__inner-container {
  background: color-mix(in srgb, var(--pl-status-warning) 14%, var(--pl-bg-canvas));
  border: 1px solid var(--pl-status-warning);
  border-radius: var(--pl-radius-md);
  color: var(--pl-text-primary);
  padding: var(--pl-space-md);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-warning .wp-block-button__link {
  background: var(--pl-status-warning);
  border: 1px solid var(--pl-status-warning);
  border-radius: var(--pl-radius-md);
  color: var(--pl-bg-canvas);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .is-style-danger:not(.wp-block-button),
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-cover.is-style-danger .wp-block-cover__inner-container {
  background: color-mix(in srgb, var(--pl-status-danger) 14%, var(--pl-bg-canvas));
  border: 1px solid var(--pl-status-danger);
  border-radius: var(--pl-radius-md);
  color: var(--pl-text-primary);
  padding: var(--pl-space-md);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-danger .wp-block-button__link {
  background: var(--pl-status-danger);
  border: 1px solid var(--pl-status-danger);
  border-radius: var(--pl-radius-md);
  color: var(--pl-bg-canvas);
}

/* Focus parity for front/editor interactions. */
:is(.wp-site-blocks, .editor-styles-wrapper) :is(
  .wp-block-button.is-style-surface,
  .wp-block-button.is-style-soft,
  .wp-block-button.is-style-outline,
  .wp-block-button.is-style-accent,
  .wp-block-button.is-style-card,
  .wp-block-button.is-style-info,
  .wp-block-button.is-style-success,
  .wp-block-button.is-style-warning,
  .wp-block-button.is-style-danger
) .wp-block-button__link:focus-visible {
  outline: 2px solid var(--pl-focus-ring);
  outline-offset: 2px;
}

/* Legacy button compatibility: no longer offered in Gutenberg, but preserved
 * for already serialized content until those classes are explicitly migrated. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-pill-primary .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-rounded-primary .wp-block-button__link {
  background-color: var(--pl-color-primary);
  border-color: var(--pl-color-primary);
  color: var(--pl-color-neutral-0);
  font-weight: 600;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-pill-secondary .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-rounded-secondary .wp-block-button__link {
  background-color: var(--pl-color-secondary);
  border-color: var(--pl-color-secondary);
  color: var(--pl-color-neutral-0);
  font-weight: 600;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-pill-outline .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-rounded-outline .wp-block-button__link {
  background-color: transparent;
  border-color: var(--pl-color-primary);
  color: var(--pl-color-primary);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-pill-surface .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-rounded-surface .wp-block-button__link {
  background-color: var(--pl-color-surface, var(--pl-bg-surface));
  border-color: var(--pl-color-outline, var(--pl-border-subtle));
  color: var(--pl-color-foreground, var(--pl-text-primary));
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-pill-primary .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-pill-secondary .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-pill-outline .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-pill-surface .wp-block-button__link {
  border-radius: var(--pl-radius-full);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-rounded-primary .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-rounded-secondary .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-rounded-outline .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-rounded-surface .wp-block-button__link {
  border-radius: var(--pl-radius-md);
}

/* Geometric button styles. Scoped to site content and the block editor only. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-cut .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-double-plate .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-fragmented-frame .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link {
  isolation: isolate;
  position: relative;
  transition: transform 180ms ease, background-color 180ms ease, color 180ms ease;
}

/* Découpe: the clip is the construction, so a native radius is incompatible. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-cut .wp-block-button__link {
  border-radius: 0;
  clip-path: polygon(0 0, calc(100% - 1rem) 0, 100% 1rem, 100% 100%, 1rem 100%, 0 calc(100% - 1rem));
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-cut .wp-block-button__link::after {
  background: currentColor;
  content: '';
  inset: 0;
  opacity: .18;
  pointer-events: none;
  position: absolute;
  transform: translate(6px, 6px);
  transition: transform 180ms ease;
  z-index: -1;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-cut .wp-block-button__link:hover::after,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-cut .wp-block-button__link:focus-visible::after {
  transform: translate(2px, 2px);
}

/* Double plaque: a second layer follows the button without imposing a color. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-double-plate .wp-block-button__link::before {
  background: currentColor;
  content: '';
  inset: 0;
  opacity: .2;
  pointer-events: none;
  position: absolute;
  transform: translate(8px, 8px);
  transition: transform 220ms ease;
  z-index: -1;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-double-plate .wp-block-button__link:hover::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-double-plate .wp-block-button__link:focus-visible::before {
  transform: translate(0, 0);
}

/* Cadre fragmenté: native borders are replaced by four animated segments. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-fragmented-frame .wp-block-button__link {
  border-color: transparent;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-fragmented-frame .wp-block-button__link::before {
  background:
    linear-gradient(currentColor, currentColor) top left / 1.5rem 2px no-repeat,
    linear-gradient(currentColor, currentColor) top right / 1.5rem 2px no-repeat,
    linear-gradient(currentColor, currentColor) bottom left / 1.5rem 2px no-repeat,
    linear-gradient(currentColor, currentColor) bottom right / 1.5rem 2px no-repeat;
  content: '';
  inset: 0;
  pointer-events: none;
  position: absolute;
  transition: background-size 220ms ease;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-fragmented-frame .wp-block-button__link:hover::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-fragmented-frame .wp-block-button__link:focus-visible::before {
  background-size:
    calc(50% - 4px) 2px,
    calc(50% - 4px) 2px,
    calc(50% - 4px) 2px,
    calc(50% - 4px) 2px;
}

/* Crochets: the button remains readable without relying on hover. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link {
  border-color: transparent;
  border-radius: 0;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link:not(.has-background):not([style*="background"]) {
  background-color: transparent;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link::after {
  border-color: currentColor;
  border-style: solid;
  content: '';
  height: .7em;
  pointer-events: none;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  transition: width 180ms ease;
  width: .7em;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link::before {
  border-width: 2px 0 0 2px;
  left: .15em;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link::after {
  border-width: 0 2px 2px 0;
  right: .15em;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link:hover::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link:focus-visible::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link:hover::after,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link:focus-visible::after {
  width: 1.1em;
}

@media (prefers-reduced-motion: reduce) {
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-cut .wp-block-button__link,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-cut .wp-block-button__link::after,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-double-plate .wp-block-button__link,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-double-plate .wp-block-button__link::before,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-fragmented-frame .wp-block-button__link::before,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link::before,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-brackets .wp-block-button__link::after {
    transition: none;
  }
}

/* V1 distinctive button interactions. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-magnetic .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-folded-corner .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-kinetic-outline .wp-block-button__link,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-press .wp-block-button__link {
  isolation: isolate;
  position: relative;
  transition: transform 220ms ease, clip-path 260ms ease;
}

/* Magnetic: JS updates these variables only on genuine hover-capable devices. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-magnetic .wp-block-button__link {
  transform: translate3d(var(--pl-button-mx, 0px), var(--pl-button-my, 0px), 0);
  transition: transform 120ms ease-out;
}

/* Touch fallback: a short visual response replaces pointer tracking. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-magnetic .wp-block-button__link:is(.is-pl-touch-visible, .is-pl-touch-active) {
  animation: pl-button-magnetic-orbit 1500ms ease-in-out both;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-magnetic .wp-block-button__link.is-pl-touch-active {
  animation-iteration-count: infinite;
}

@keyframes pl-button-magnetic-orbit {
  0% {
    transform: translate3d(0, -4px, 0) scale(1.01);
  }
  25% {
    transform: translate3d(5px, 0, 0) scale(1.03);
  }
  50% {
    transform: translate3d(0, 4px, 0) scale(1.01);
  }
  75% {
    transform: translate3d(-5px, 0, 0) scale(1.03);
  }
  100% {
    transform: translate3d(0, -4px, 0) scale(1.01);
  }
}

/* Gooey: reproduce the reference interaction with two moving blobs. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey {
  filter: url('../../svg/button-gooey.svg#pl-button-gooey');
  isolation: isolate;
  position: relative;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link {
  border: 0 !important;
  position: relative;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link::after {
  background: inherit;
  border-radius: 50%;
  content: '';
  display: inline-block;
  height: 0;
  pointer-events: none;
  position: absolute;
  transition: height 2s ease, width 2s ease;
  width: 0;
  z-index: -1;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link::before {
  animation: pl-button-gooey-drift-before 2.4s ease-in-out -0.45s infinite alternate;
  left: -10%;
  top: -25%;
  transform-origin: 50% 50%;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link::after {
  animation: pl-button-gooey-drift-after 3.1s ease-in-out -1.1s infinite alternate-reverse;
  bottom: -25%;
  left: 0;
  transform-origin: 50% 50%;
}

@keyframes pl-button-gooey-drift-before {
  from { left: -10%; }
  to { left: calc(100% - 4.4em); }
}

@keyframes pl-button-gooey-drift-after {
  from { left: 0; }
  to { left: calc(100% - 4.4em); }
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link:hover::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link:focus-visible::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link.is-pl-touch-visible::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link.is-pl-touch-active::before {
  height: 2.95em;
  width: 4.4em;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link:hover::after,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link:focus-visible::after,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link.is-pl-touch-visible::after,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link.is-pl-touch-active::after {
  height: 2.95em;
  width: 4.4em;
}

/* Diaphragm: two shutters open away from the center. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link::after {
  background: color-mix(in srgb, currentColor 18%, transparent);
  content: '';
  inset: 0;
  pointer-events: none;
  position: absolute;
  transition: transform 260ms ease;
  z-index: -1;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link::before {
  clip-path: polygon(0 0, 52% 0, 50% 100%, 0 100%);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link::after {
  clip-path: polygon(48% 0, 100% 0, 100% 100%, 50% 100%);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link:hover::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link:focus-visible::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link.is-pl-touch-visible::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link.is-pl-touch-active::before {
  transform: translateX(-20%);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link:hover::after,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link:focus-visible::after,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link.is-pl-touch-visible::after,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link.is-pl-touch-active::after {
  transform: translateX(20%);
}

/* Folded corner: the corner lifts without changing the button's content. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-folded-corner .wp-block-button__link::after {
  background: currentColor;
  clip-path: polygon(100% 0, 100% 100%, 0 0);
  content: '';
  height: 1.1em;
  opacity: .28;
  pointer-events: none;
  position: absolute;
  right: 0;
  top: 0;
  transform-origin: top right;
  transition: transform 220ms ease;
  width: 1.1em;
  z-index: 1;
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-folded-corner .wp-block-button__link:hover::after,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-folded-corner .wp-block-button__link:focus-visible::after {
  transform: rotate(90deg);
}

/* Kinetic outline: a moving conic segment builds the contour. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-kinetic-outline .wp-block-button__link::before {
  background: conic-gradient(from 0deg, transparent 0 72%, currentColor 82% 100%);
  content: '';
  inset: -2px;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  padding: 2px;
  pointer-events: none;
  position: absolute;
  transform: rotate(0deg);
  transition: transform 700ms cubic-bezier(.2, .8, .2, 1);
}

:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-kinetic-outline .wp-block-button__link:hover::before,
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-kinetic-outline .wp-block-button__link:focus-visible::before {
  transform: rotate(360deg);
}

/* Press: activation only; focus remains a separate accessibility state. */
:is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-press .wp-block-button__link:active {
  transform: scale(.95) skewX(-2deg);
}

@media (prefers-reduced-motion: reduce) {
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-magnetic .wp-block-button__link,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link::before,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-gooey .wp-block-button__link::after,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link::before,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-diaphragm .wp-block-button__link::after,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-folded-corner .wp-block-button__link::after,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-kinetic-outline .wp-block-button__link::before,
  :is(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button.is-style-press .wp-block-button__link {
    animation: none;
    transition: none;
  }
}
