/**
 * GastroFlow product page — scoped presentation.
 * Uses FENIX tokens (--fx-*) with fallbacks. Does not redefine global tokens.
 */

body.fenix-gf-product {
  background: var(--fx-paper, #F0F1F1) !important;
  color: var(--fx-text-on-paper, #212225);
}

body.fenix-gf-product .wp-block-post-title {
  display: none;
}

.fenix-gf {
  --gf-ink: var(--fx-ink, #212225);
  --gf-paper: var(--fx-paper, #F0F1F1);
  --gf-paper-2: var(--fx-paper-2, #EEF0FE);
  /* Text-safe ember on paper (≥4.5:1); brand gold #CF9622 is UI/fill only */
  --gf-ember: var(--fx-ember-on-paper, #73520e);
  --gf-ember-hover: var(--fx-ember-hover, #a07318);
  --gf-accent: var(--fx-accent, #225BCF);
  --gf-muted: var(--fx-muted, #565048);
  --gf-line: var(--fx-line, rgba(33, 34, 37, 0.12));
  --gf-on-ink: var(--fx-text-on-ink, #F0F1F1);
  --gf-on-paper: var(--fx-text-on-paper, #212225);
  --gf-display: var(--fx-font-display, "Red Hat Display", ui-sans-serif, system-ui, sans-serif);
  --gf-text: var(--fx-font-text, "Red Hat Text", ui-sans-serif, system-ui, sans-serif);
  box-sizing: border-box;
  color: var(--gf-on-paper);
  font-family: var(--gf-text);
  overflow-x: clip;
  width: 100%;
}

.fenix-gf *,
.fenix-gf *::before,
.fenix-gf *::after {
  box-sizing: border-box;
}

.fenix-gf a:focus-visible,
.fenix-gf button:focus-visible {
  outline: 2px solid var(--gf-accent, #225BCF);
  outline-offset: 2px;
}

.fenix-gf__wrap {
  margin-inline: auto;
  max-width: 72rem;
  padding-inline: clamp(1.25rem, 4vw, 2.5rem);
  width: 100%;
}

.fenix-gf__section {
  padding-block: clamp(3rem, 6vw, 5.5rem);
}

.fenix-gf__section--paper {
  background: var(--madera-cream, var(--gf-paper));
}

.fenix-gf__section--paper-2 {
  background: var(--gf-paper-2);
}

.fenix-gf__section--ink {
  background: var(--gf-paper-2);
  color: var(--gf-on-paper);
}

.fenix-gf__eyebrow {
  color: var(--fx-accent, #225BCF);
  font-family: var(--gf-display);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  margin: 0 0 0.75rem;
  text-transform: uppercase;
}

.fenix-gf__section--ink .fenix-gf__eyebrow {
  color: var(--gf-accent, #225BCF);
}

.fenix-gf h1,
.fenix-gf h2,
.fenix-gf h3 {
  font-family: var(--gf-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0;
}

.fenix-gf h1 {
  font-size: clamp(2rem, 4vw, 3.25rem);
  font-weight: 600;
  max-width: 18ch;
}

.fenix-gf h2 {
  font-size: clamp(1.5rem, 2.5vw, 2.125rem);
  max-width: 28ch;
}

.fenix-gf h3 {
  font-size: clamp(1.125rem, 1.5vw, 1.375rem);
}

.fenix-gf p {
  font-size: 1.0625rem;
  line-height: 1.65;
  margin: 0;
}

.fenix-gf__lead {
  color: var(--gf-muted);
  margin-top: 1.25rem;
  max-width: 62ch;
}

.fenix-gf__section--ink .fenix-gf__lead,
.fenix-gf__section--ink .fenix-gf__note {
  color: var(--gf-muted);
}

.fenix-gf__note {
  color: var(--gf-muted);
  font-size: 0.9375rem;
  margin-top: 0.75rem;
  max-width: 62ch;
}

.fenix-gf__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.75rem;
}

.fenix-gf__btn {
  align-items: center;
  border: 1px solid transparent;
  border-radius: 8px;
  display: inline-flex;
  font-family: var(--gf-display);
  font-size: 0.9375rem;
  font-weight: 500;
  justify-content: center;
  min-height: 44px;
  padding: 0.7rem 1.15rem;
  text-decoration: none;
  transition: background-color 180ms ease, color 180ms ease, border-color 180ms ease;
}

.fenix-gf__btn--primary {
  background: var(--gf-accent, #225BCF);
  color: #fff;
}

.fenix-gf__btn--primary:hover,
.fenix-gf__btn--primary:focus-visible {
  background: color-mix(in srgb, var(--gf-accent, #225BCF) 88%, #000);
  color: #fff;
}

.fenix-gf__btn--ghost {
  background: transparent;
  border-color: var(--gf-line);
  color: var(--gf-on-paper);
}

.fenix-gf__btn--ghost:hover,
.fenix-gf__btn--ghost:focus-visible {
  border-color: var(--gf-ink);
  color: var(--gf-ink);
}

.fenix-gf__section--ink .fx-btn-secondary,
.fenix-gf__section--ink .fenix-gf__btn--ghost {
  border-color: color-mix(in srgb, var(--gf-on-paper) 28%, transparent);
  color: var(--gf-on-paper);
}

.fenix-gf__section--ink .fx-btn-secondary:hover,
.fenix-gf__section--ink .fenix-gf__btn--ghost:hover {
  border-color: var(--gf-accent, #225BCF);
}

.fenix-gf__hero {
  border-bottom: 1px solid var(--gf-line);
}

.fenix-gf__hero-inner {
  padding-block: clamp(3.25rem, 8vw, 6.5rem);
}

.fenix-gf__byline {
  color: var(--gf-muted);
  font-size: 0.9375rem;
  margin-top: 0.85rem;
}

.fenix-gf__compare {
  display: grid;
  gap: 1.25rem;
  margin-top: 2rem;
}

@media (min-width: 782px) {
  .fenix-gf__compare {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
}

.fenix-gf__compare-col {
  padding: 1.25rem 0;
  border-top: 1px solid var(--gf-line);
}

.fenix-gf__compare-col--after {
  border-top-color: color-mix(in srgb, var(--gf-accent, #225BCF) 45%, var(--gf-line));
}

.fenix-gf__compare-col h3 {
  margin-top: 0.35rem;
  font-size: clamp(1.2rem, 2vw, 1.5rem);
}

.fenix-gf__compare-list {
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.fenix-gf__compare-list li {
  position: relative;
  margin: 0.45rem 0 0;
  padding-left: 1rem;
  color: var(--gf-muted);
  line-height: 1.55;
}

.fenix-gf__compare-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 0.4rem;
  height: 1px;
  background: var(--gf-ink);
}

.fenix-gf__compare-col--after .fenix-gf__compare-list li::before {
  background: var(--gf-accent, #225BCF);
}

/* Benefits: typography, not cards. Numbers only on the Ablauf-Sequenz. */
.fenix-gf__benefits {
  border-top: 1px solid var(--gf-line);
  display: grid;
  gap: 0;
  list-style: none;
  margin: 2.5rem 0 0;
  padding: 0;
}

.fenix-gf__benefit {
  border-bottom: 1px solid var(--gf-line);
  display: grid;
  gap: 0.75rem 2rem;
  grid-template-columns: 3.25rem minmax(0, 1fr);
  padding-block: 1.5rem;
}

.fenix-gf__benefits--plain .fenix-gf__benefit {
  grid-template-columns: minmax(0, 1fr);
}

.fenix-gf__benefit-num {
  color: var(--gf-accent, #225BCF);
  font-family: var(--gf-display);
  font-size: 1.125rem;
  font-weight: 600;
  line-height: 1.4;
}

.fenix-gf__benefit h3,
.fenix-gf__benefit p {
  margin: 0;
}

.fenix-gf__benefit h3 {
  font-size: clamp(1.25rem, 2vw, 1.625rem);
  font-weight: 500;
  max-width: none;
}

.fenix-gf__benefit p {
  color: var(--gf-muted);
  margin-top: 0.4rem;
  max-width: 58ch;
}

/* Large media */
.fenix-gf__media {
  margin: 0;
  min-width: 0;
}

.fenix-gf__media img {
  background: var(--gf-paper-2);
  border: 1px solid var(--gf-line);
  border-radius: 12px;
  display: block;
  height: auto;
  max-width: 100%;
  object-fit: cover;
  width: 100%;
}

.fenix-gf__media--hero img {
  aspect-ratio: 16 / 9;
  border-radius: 16px;
}

.fenix-gf__media figcaption {
  color: var(--gf-muted);
  font-size: 0.8125rem;
  line-height: 1.5;
  margin-top: 0.75rem;
  max-width: 68ch;
}

.fenix-gf__shots {
  display: grid;
  gap: 1.75rem;
  margin-top: 2.25rem;
}

.fenix-gf__shots--pair {
  grid-template-columns: 1fr;
}

@media (min-width: 900px) {
  .fenix-gf__shots--pair {
    gap: 2rem;
    grid-template-columns: 1fr 1fr;
  }
}

/* Workflow: vertical sequence */
.fenix-gf__flow {
  display: grid;
  gap: 0;
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
}

.fenix-gf__flow-step {
  display: grid;
  gap: 0.35rem 1.5rem;
  grid-template-columns: 2.5rem minmax(0, 1fr);
  padding-block: 1.15rem;
  position: relative;
}

.fenix-gf__flow-step:not(:last-child)::before {
  background: var(--gf-line);
  content: "";
  height: calc(100% - 2rem);
  left: 0.7rem;
  position: absolute;
  top: 2.35rem;
  width: 1px;
}

.fenix-gf__flow-n {
  color: var(--gf-accent, #225BCF);
  font-family: var(--gf-display);
  font-size: 1rem;
  font-weight: 600;
}

.fenix-gf__flow-step strong {
  display: block;
  font-family: var(--gf-display);
  font-size: 1.125rem;
  font-weight: 600;
}

.fenix-gf__flow-step p {
  color: var(--gf-muted);
  font-size: 1rem;
}

/* Functions: definition list */
.fenix-gf__defs {
  border-top: 1px solid var(--gf-line);
  margin: 2.25rem 0 0;
  padding: 0;
}

.fenix-gf__defs > div {
  border-bottom: 1px solid var(--gf-line);
  display: grid;
  gap: 0.5rem 2.5rem;
  padding-block: 1.35rem;
}

@media (min-width: 782px) {
  .fenix-gf__defs > div {
    grid-template-columns: minmax(10rem, 16rem) minmax(0, 1fr);
  }
}

.fenix-gf__defs dt {
  font-family: var(--gf-display);
  font-size: 1.0625rem;
  font-weight: 600;
  margin: 0;
}

.fenix-gf__defs dd {
  color: var(--gf-muted);
  font-size: 1.02rem;
  line-height: 1.6;
  margin: 0;
  max-width: 58ch;
}

.fenix-gf__split {
  display: grid;
  gap: 2rem;
}

@media (min-width: 900px) {
  .fenix-gf__split {
    align-items: start;
    gap: 4rem;
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.15fr);
  }
}

.fenix-gf__links {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  margin-top: 1.75rem;
}

.fenix-gf__link-row {
  border-top: 1px solid var(--gf-line);
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.25rem;
  justify-content: space-between;
  padding-top: 1.15rem;
  text-decoration: none;
}

.fenix-gf__link-row:last-child {
  border-bottom: 1px solid var(--gf-line);
  padding-bottom: 1.15rem;
}

.fenix-gf__link-row strong {
  color: inherit;
  font-family: var(--gf-display);
  font-size: 1.125rem;
  font-weight: 600;
}

.fenix-gf__link-row span {
  color: var(--gf-muted);
  font-size: 0.9375rem;
}

.fenix-gf__section--ink .fenix-gf__link-row {
  border-color: var(--gf-line);
  color: var(--gf-on-paper);
}

.fenix-gf__section--ink .fenix-gf__link-row span {
  color: var(--gf-muted);
}

.fenix-gf__section--ink .fenix-gf__link-row:hover strong {
  color: var(--gf-accent, #225BCF);
}

.fenix-gf-cta.fenix-madera-cta {
  background: var(--fx-paper-2, #EEF0FE);
  border: 1px solid var(--fx-line, rgba(33, 34, 37, 0.12));
  border-radius: 16px;
  overflow: hidden;
}

.fenix-gf-cta .fenix-madera-cta__glow {
  display: none;
}

.fenix-gf-cta .fenix-madera-cta__title {
  color: var(--fx-text-on-paper, #212225);
  font-family: "Red Hat Display", var(--font-display, ui-sans-serif), sans-serif;
  font-size: clamp(1.5rem, 2.5vw, 2.125rem);
  font-weight: 600;
}

.fenix-gf-cta .fenix-madera-cta__text {
  color: color-mix(in srgb, var(--fx-text-on-paper, #212225) 85%, transparent);
  max-width: 58ch;
}

.fenix-gf-cta .fenix-madera-btn {
  border-radius: 8px;
  min-height: 44px;
}

.fenix-gf-cta .fenix-madera-btn--primary {
  background: var(--fx-accent, #225BCF);
  color: #fff;
}

.fenix-docs-toc__group {
  margin: 1.25rem 0 0.4rem;
  font-family: var(--gf-display, var(--fx-font-display, "Red Hat Display", sans-serif));
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fx-accent, #225BCF);
}

.fenix-docs-toc__group:first-child {
  margin-top: 0;
}

.fenix-docs-audience {
  margin: 0 0 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--gf-line, var(--fx-line, rgba(26, 28, 30, 0.12)));
  scroll-margin-top: 5rem;
}

.fenix-docs-audience h2 {
  margin: 0.35rem 0 0;
  font-size: clamp(1.35rem, 2.2vw, 1.75rem);
}

/* Docs: editorial module blocks — definition layout, not icon cards */
.fenix-docs-module {
  margin-top: 1.75rem;
}

.fenix-docs-module + .fenix-docs-module {
  margin-top: 2.25rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--gf-line, var(--fx-line, rgba(26, 28, 30, 0.12)));
}

.fenix-docs-module .fx-kicker {
  margin-bottom: 0.5rem;
}

.fenix-docs-module h3 {
  font-family: var(--gf-display, var(--fx-font-display, "Red Hat Display", sans-serif));
  font-size: clamp(1.25rem, 2vw, 1.5rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin: 0 0 0.65rem;
}

.fenix-docs-module .fx-prose {
  margin: 0;
}

.fenix-docs-module__facts {
  border-top: 1px solid var(--gf-line, var(--fx-line, rgba(26, 28, 30, 0.12)));
  margin: 1.35rem 0 0;
  padding: 0;
}

.fenix-docs-module__facts > div {
  border-bottom: 1px solid var(--gf-line, var(--fx-line, rgba(26, 28, 30, 0.12)));
  display: grid;
  gap: 0.35rem 2rem;
  padding-block: 1.1rem;
}

@media (min-width: 782px) {
  .fenix-docs-module__facts > div {
    align-items: start;
    grid-template-columns: minmax(9rem, 12rem) minmax(0, 1fr);
  }
}

.fenix-docs-module__facts dt {
  font-family: var(--gf-display, var(--fx-font-display, "Red Hat Display", sans-serif));
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  margin: 0;
  text-transform: uppercase;
}

.fenix-docs-module__facts dd {
  color: var(--gf-muted, var(--fx-muted, #565048));
  font-size: 1.02rem;
  line-height: 1.6;
  margin: 0;
  max-width: 62ch;
}

.fenix-docs-module__facts .fx-list {
  margin: 0;
}

.fenix-docs-module__facts .fx-list li + li {
  margin-top: 0.35rem;
}

.fenix-docs-module__note,
.fenix-docs-module__links {
  margin: 1rem 0 0;
  max-width: 62ch;
}

.fenix-docs-module__links a {
  text-underline-offset: 0.18em;
}

.fenix-docs-module {
  scroll-margin-top: 1.25rem;
}

.fenix-madera-feature__icon .fx-icon,
.fenix-docs-section__icon .fx-icon,
.fenix-madera-channel__icon .fx-icon {
  color: var(--fx-accent, #225BCF);
  display: block;
  vertical-align: middle;
}

.fenix-madera-channel__cta .fx-icon,
.fenix-docs-section__arrow .fx-icon {
  color: inherit;
  margin-inline-start: 0.25rem;
  vertical-align: -0.2em;
}

@media (max-width: 480px) {
  .fenix-gf__benefit {
    grid-template-columns: 2.25rem minmax(0, 1fr);
  }

  .fenix-gf__actions {
    flex-direction: column;
  }

  .fenix-gf__btn {
    width: 100%;
  }
}
