/* Default CTA: design-tokens/tokens.json → button.primary */
.fv-theme-toggle,
.site-header .ast-custom-button-link,
.site-header .menu-item .ast-custom-button-link,
body .ast-button,
body .entry-content .wp-element-button,
body .entry-content .wp-block-button__link,
body .entry-content .wp-block-search__button,
body .comment-form input[type="submit"],
body .post-password-form input[type="submit"],
body .search-form input[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 56px;
  padding: 0.78rem 1.2rem;
  border: 1px solid color-mix(in srgb, var(--color-accent-strong) 58%, transparent);
  border-radius: 0.625rem;
  background:
    linear-gradient(180deg, color-mix(in srgb, white 8%, var(--color-accent)), color-mix(in srgb, var(--color-accent-strong) 90%, black));
  box-shadow:
    inset 0 1px 0 var(--fv-highlight-inset),
    var(--shadow-sm);
  color: var(--fv-text-on-accent);
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition:
    transform var(--transition-fast),
    border-color var(--transition-fast),
    background-color var(--transition-fast),
    box-shadow var(--transition-fast),
    filter var(--transition-fast),
    color var(--transition-fast);
}

.fv-theme-toggle:hover,
.fv-theme-toggle:focus-visible,
.site-header .ast-custom-button-link:hover,
.site-header .ast-custom-button-link:focus-visible,
body .ast-button:hover,
body .ast-button:focus-visible,
body .entry-content .wp-element-button:hover,
body .entry-content .wp-block-button__link:hover,
body .entry-content .wp-block-search__button:hover,
body .comment-form input[type="submit"]:hover,
body .post-password-form input[type="submit"]:hover,
body .search-form input[type="submit"]:hover {
  transform: scale(1.02);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    var(--shadow-sm);
  color: var(--fv-text-on-accent);
  border-color: color-mix(in srgb, var(--color-accent) 72%, transparent);
  filter: saturate(1.04) brightness(1.02);
}

body .entry-content .wp-element-button:focus-visible,
body .entry-content .wp-block-button__link:focus-visible,
body .entry-content .wp-block-search__button:focus-visible,
body .comment-form input[type="submit"]:focus-visible,
body .post-password-form input[type="submit"]:focus-visible,
body .search-form input[type="submit"]:focus-visible,
body .ast-button:focus-visible {
  outline: none;
  box-shadow: var(--shadow-md), var(--focus-ring);
}

body .entry-content .wp-element-button.is-style-outline,
body .entry-content .wp-block-button.is-style-outline > .wp-block-button__link,
body .entry-content .wp-block-file .wp-block-file__button,
body .ast-button.ast-outline,
body .ast-button.ast-button-outline {
  border-color: color-mix(in srgb, var(--color-accent) 20%, var(--color-border));
  background:
    linear-gradient(180deg, color-mix(in srgb, white 3%, var(--color-surface-soft)), color-mix(in srgb, var(--color-surface) 98%, transparent));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 10px 18px rgba(0, 0, 0, 0.08);
  color: var(--color-text);
}

body .entry-content .wp-element-button.is-style-outline:hover,
body .entry-content .wp-block-button.is-style-outline > .wp-block-button__link:hover,
body .entry-content .wp-block-file .wp-block-file__button:hover,
body .ast-button.ast-outline:hover,
body .ast-button.ast-button-outline:hover {
  border-color: color-mix(in srgb, var(--color-accent) 46%, transparent);
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--color-accent) 9%, var(--color-surface-soft)), color-mix(in srgb, var(--color-surface) 100%, transparent));
  color: var(--color-text);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 14px 24px color-mix(in srgb, var(--color-accent) 10%, transparent);
}

body .entry-content .wp-block-buttons {
  gap: 0.75rem;
}

body .entry-content .wp-block-button__link,
body .entry-content .wp-element-button {
  min-width: min(100%, 14rem);
}

body .entry-content .wp-block-button.is-style-outline > .wp-block-button__link {
  border-width: 1px;
}

/* Kanonisches Seiten-CTA-System.
 * Abgeleitet aus front-page/protect: pill-shaped, ruhig, ohne Gradient.
 * Page-CSS darf nur Varianten/Abstände ergänzen, nicht das Grundverhalten kopieren.
 */
.fv-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.78rem 1.2rem;
  border-radius: 0.625rem;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition:
    opacity var(--transition-fast),
    transform var(--transition-base),
    background var(--transition-base),
    border-color var(--transition-base),
    box-shadow var(--transition-base),
    color var(--transition-base);
}

.fv-btn--pill {
  padding-inline: 1.75rem;
  border-radius: 9999px;
}

.fv-btn svg {
  flex-shrink: 0;
}

.fv-btn--primary {
  background: var(--color-accent);
  color: var(--fv-text-on-accent);
  border: 1px solid var(--color-accent-strong);
  box-shadow:
    inset 0 1px 0 var(--fv-highlight-inset),
    var(--shadow-sm);
}

.fv-btn--primary:hover,
.fv-btn--primary:focus-visible {
  background: var(--color-accent-strong);
  box-shadow:
    inset 0 1px 0 color-mix(in srgb, white 22%, transparent),
    var(--shadow-sm);
  transform: scale(1.02);
  color: var(--fv-text-on-accent);
}

.fv-btn--outline {
  background: transparent;
  color: var(--color-text);
  border: 1px solid var(--color-border-strong);
}

.fv-btn--outline:hover,
.fv-btn--outline:focus-visible {
  background: color-mix(in srgb, var(--color-accent) 8%, transparent);
  border-color: var(--color-accent-strong);
  color: var(--color-accent-strong);
  box-shadow: var(--shadow-sm);
  transform: none;
}

.fv-btn--ghost {
  background: transparent;
  color: var(--color-accent);
  border: 1px solid transparent;
  padding-inline: 1.25rem;
}

.fv-btn--ghost:hover,
.fv-btn--ghost:focus-visible {
  background: color-mix(in srgb, var(--color-accent) 8%, transparent);
  border-color: color-mix(in srgb, var(--color-accent) 30%, transparent);
  color: var(--color-accent-strong);
}

/* Kanonische Inquiry-Form-Submit-Buttons fuer die sechs Produkt-/Demo-Seiten.
 * Die Formulare kommen per Shortcode ins Markup, daher wird die zentrale
 * Premium-Button-Basis hier ueber die Footer-Selektoren gebuendelt statt
 * page-lokal mehrfach dupliziert.
 */
.fv-smart-home .fv-smart-home__form-footer button,
.fv-it-sicherheit .fv-itsec__form-footer button,
.fv-individuelle-integration .fv-integration__form-footer button,
.fv-smart-building .fv-smart-building__form-footer button,
.fv-netzwerk-demo .fv-netzwerk-demo__form-footer button,
.fv-smart-home-vorschau .fv-demo__form-footer button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 3.15rem;
  padding: 0.8rem 1.25rem;
  border: 1px solid color-mix(in srgb, var(--color-accent-strong) 58%, transparent);
  border-radius: 999px;
  background:
    linear-gradient(180deg, color-mix(in srgb, white 8%, var(--color-accent)), color-mix(in srgb, var(--color-accent-strong) 90%, black));
  box-shadow:
    inset 0 1px 0 var(--fv-highlight-inset),
    0 16px 30px color-mix(in srgb, var(--color-accent) 20%, transparent);
  color: var(--fv-text-on-accent);
  font-weight: 750;
  cursor: pointer;
  transition:
    transform var(--transition-base),
    box-shadow var(--transition-base),
    border-color var(--transition-base);
}

.fv-smart-home .fv-smart-home__form-footer button:hover,
.fv-smart-home .fv-smart-home__form-footer button:focus-visible,
.fv-it-sicherheit .fv-itsec__form-footer button:hover,
.fv-it-sicherheit .fv-itsec__form-footer button:focus-visible,
.fv-individuelle-integration .fv-integration__form-footer button:hover,
.fv-individuelle-integration .fv-integration__form-footer button:focus-visible,
.fv-smart-building .fv-smart-building__form-footer button:hover,
.fv-smart-building .fv-smart-building__form-footer button:focus-visible,
.fv-netzwerk-demo .fv-netzwerk-demo__form-footer button:hover,
.fv-netzwerk-demo .fv-netzwerk-demo__form-footer button:focus-visible,
.fv-smart-home-vorschau .fv-demo__form-footer button:hover,
.fv-smart-home-vorschau .fv-demo__form-footer button:focus-visible {
  transform: scale(1.02);
  border-color: color-mix(in srgb, var(--color-accent) 72%, transparent);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    0 16px 30px color-mix(in srgb, var(--color-accent) 20%, transparent);
}

body .entry-content .wp-element-button[disabled],
body .entry-content .wp-block-button__link[disabled],
body .ast-button[disabled] {
  opacity: 0.52;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

html[data-theme="light"] .fv-theme-toggle,
html[data-theme="light"] .site-header .ast-custom-button-link,
html[data-theme="light"] .site-header .menu-item .ast-custom-button-link,
html[data-theme="light"] body .ast-button,
html[data-theme="light"] body .entry-content .wp-element-button,
html[data-theme="light"] body .entry-content .wp-block-button__link,
html[data-theme="light"] body .entry-content .wp-block-search__button,
html[data-theme="light"] body .comment-form input[type="submit"],
html[data-theme="light"] body .post-password-form input[type="submit"],
html[data-theme="light"] body .search-form input[type="submit"] {
  color: #ffffff;
}

html[data-theme="dark"] .fv-theme-toggle,
html[data-theme="dark"] .site-header .ast-custom-button-link,
html[data-theme="dark"] .site-header .menu-item .ast-custom-button-link,
html[data-theme="dark"] body .ast-button,
html[data-theme="dark"] body .entry-content .wp-element-button,
html[data-theme="dark"] body .entry-content .wp-block-button__link,
html[data-theme="dark"] body .entry-content .wp-block-search__button,
html[data-theme="dark"] body .comment-form input[type="submit"],
html[data-theme="dark"] body .post-password-form input[type="submit"],
html[data-theme="dark"] body .search-form input[type="submit"] {
  color: var(--fv-text-on-accent);
}

body .entry-content a:not(.wp-block-button__link):not(.wp-element-button):not(.button):not(.fv-btn) {
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, currentColor 28%, transparent);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
  transition:
    color var(--transition-fast),
    text-decoration-color var(--transition-fast);
}

body .entry-content a:not(.wp-block-button__link):not(.wp-element-button):not(.button):not(.fv-btn):hover,
body .entry-content a:not(.wp-block-button__link):not(.wp-element-button):not(.button):not(.fv-btn):focus-visible {
  text-decoration-thickness: 0.1em;
  text-decoration-color: currentColor;
}

@media (max-width: 768px) {
  body .ast-button,
  body .entry-content .wp-block-button__link,
  body .entry-content .wp-element-button,
  body .entry-content .wp-block-search__button,
  body .comment-form input[type="submit"],
  body .post-password-form input[type="submit"],
  body .search-form input[type="submit"],
  .fv-btn {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .fv-theme-toggle,
  body .ast-button,
  body .entry-content .wp-block-button__link,
  body .entry-content .wp-element-button,
  body .entry-content .wp-block-search__button,
  body .comment-form input[type="submit"],
  body .post-password-form input[type="submit"],
  body .search-form input[type="submit"] {
    min-height: 3.15rem;
    padding-left: 1rem;
    padding-right: 1rem;
  }
}
