/*
 * DBC / BIOTEN V2.8.1
 * Causal paths, internal-link semantics and cross-page decision refinement.
 *
 * The confirmed homepage hero remains untouched. This layer gives secondary
 * pages a visible "context → current step → next decision" structure without
 * introducing another family of decorative cards.
 */

body.v281-site {
  --v281-blue: #075aa8;
  --v281-blue-bright: #1b86d6;
  --v281-green: #087d59;
  --v281-green-bright: #27a475;
  --v281-ink: #061f35;
  --v281-text: #344d5e;
  --v281-muted: #71828c;
  --v281-paper: #fbfcfc;
  --v281-line: rgba(7, 52, 95, .13);
  --v281-line-strong: rgba(7, 52, 95, .23);
  --v281-shell: min(1180px, calc(100vw - 64px));
  --v281-ease: cubic-bezier(.22, 1, .36, 1);
}

body.v281-site[data-v270-family="bioten"],
body.v281-site[data-v270-family="developer"] {
  --v281-accent: var(--v281-green);
  --v281-support: var(--v281-blue);
}

body.v281-site:not([data-v270-family="bioten"]):not([data-v270-family="developer"]) {
  --v281-accent: var(--v281-blue);
  --v281-support: var(--v281-green);
}

/* Anchors must land below the fixed site and context navigation. */
body.v281-site:not(.home-v281) main :is(section, article, div)[id] {
  scroll-margin-top: 9.5rem;
}

body.v281-site :where(a, button, input, select, textarea, summary):focus-visible {
  outline: 2px solid color-mix(in srgb, var(--v281-accent) 74%, white);
  outline-offset: 4px;
}

body.v281-site .footer-directory a[aria-current="page"],
body.v281-site .formal-footer-cta a[aria-current="page"] {
  color: var(--v281-ink);
  text-decoration-color: color-mix(in srgb, var(--v281-accent) 54%, transparent);
  text-underline-offset: .28em;
}

/* ---------- cross-page relationship path ---------- */

body.v281-site:not(.home-v281) .v281-path {
  position: relative;
  z-index: 3;
  border-block: 1px solid var(--v281-line);
  background:
    linear-gradient(90deg, rgba(7, 90, 168, .025), rgba(8, 125, 89, .034)),
    rgba(251, 252, 252, .96);
}

body.v281-site:not(.home-v281) .v281-path::before {
  content: "";
  position: absolute;
  inset: -1px auto auto 0;
  inline-size: clamp(8rem, 21vw, 21rem);
  block-size: 1px;
  background: linear-gradient(90deg, var(--v281-accent), var(--v281-support));
}

body.v281-site:not(.home-v281) .v281-path__inner {
  inline-size: var(--v281-shell);
  margin-inline: auto;
  padding-block: clamp(1.2rem, 2vw, 1.75rem);
  display: grid;
  grid-template-columns: minmax(150px, .72fr) minmax(0, 3.28fr);
  gap: clamp(1.5rem, 3.5vw, 3.6rem);
  align-items: center;
}

body.v281-site:not(.home-v281) .v281-path__intro {
  min-inline-size: 0;
}

body.v281-site:not(.home-v281) .v281-path__intro > span {
  display: block;
  margin-block-end: .42rem;
  color: var(--v281-accent);
  font-size: .59rem;
  font-weight: 780;
  line-height: 1.2;
  letter-spacing: .16em;
}

body.v281-site:not(.home-v281) .v281-path__intro > strong {
  display: block;
  color: var(--v281-ink);
  font-size: clamp(.9rem, 1.05vw, 1rem);
  font-weight: 680;
  line-height: 1.42;
  letter-spacing: -.018em;
}

body.v281-site:not(.home-v281) .v281-path ol {
  min-inline-size: 0;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  list-style: none;
}

body.v281-site:not(.home-v281) .v281-path li {
  position: relative;
  min-inline-size: 0;
}

body.v281-site:not(.home-v281) .v281-path li:not(:last-child)::after {
  content: "";
  position: absolute;
  z-index: 0;
  inset: 1.17rem -.3rem auto auto;
  inline-size: .6rem;
  block-size: 1px;
  background: var(--v281-line-strong);
}

body.v281-site:not(.home-v281) .v281-path__item {
  position: relative;
  z-index: 1;
  min-block-size: 4.4rem;
  padding: .55rem clamp(.7rem, 1.2vw, 1rem);
  display: grid;
  grid-template-columns: 1.7rem minmax(0, 1fr) auto;
  gap: .55rem;
  align-items: start;
  color: var(--v281-text);
  text-decoration: none;
  border-inline-start: 1px solid var(--v281-line);
  transition:
    color 240ms var(--v281-ease),
    background-color 240ms var(--v281-ease),
    transform 240ms var(--v281-ease);
}

body.v281-site:not(.home-v281) a.v281-path__item:hover {
  color: var(--v281-ink);
  background: rgba(255, 255, 255, .72);
  transform: translateY(-2px);
}

body.v281-site:not(.home-v281) [data-v281-current] .v281-path__item {
  color: var(--v281-ink);
  background:
    linear-gradient(115deg,
      color-mix(in srgb, var(--v281-accent) 8%, transparent),
      color-mix(in srgb, var(--v281-support) 6%, transparent));
}

body.v281-site:not(.home-v281) [data-v281-current] .v281-path__item::after {
  content: "";
  position: absolute;
  inset: auto .75rem 0 .75rem;
  block-size: 2px;
  background: linear-gradient(90deg, var(--v281-accent), var(--v281-support));
}

body.v281-site:not(.home-v281) .v281-path__number {
  color: var(--v281-accent);
  font-size: .63rem;
  font-weight: 780;
  line-height: 1.85;
  letter-spacing: .07em;
}

body.v281-site:not(.home-v281) .v281-path__copy {
  min-inline-size: 0;
}

body.v281-site:not(.home-v281) .v281-path__copy strong,
body.v281-site:not(.home-v281) .v281-path__copy small {
  display: block;
}

body.v281-site:not(.home-v281) .v281-path__copy strong {
  color: inherit;
  font-size: .82rem;
  font-weight: 690;
  line-height: 1.45;
  letter-spacing: -.012em;
}

body.v281-site:not(.home-v281) .v281-path__copy small {
  margin-block-start: .2rem;
  color: var(--v281-muted);
  font-size: .65rem;
  font-weight: 470;
  line-height: 1.42;
}

body.v281-site:not(.home-v281) .v281-path__arrow {
  margin-block-start: .05rem;
  color: color-mix(in srgb, var(--v281-accent) 60%, var(--v281-muted));
  font-size: .78rem;
  line-height: 1.5;
  transition: transform 240ms var(--v281-ease);
}

body.v281-site:not(.home-v281) a.v281-path__item:hover .v281-path__arrow {
  transform: translateX(3px);
}

body.v281-site:not(.home-v281) [data-v281-current] .v281-path__arrow {
  inline-size: .42rem;
  block-size: .42rem;
  margin-block-start: .42rem;
  border-radius: 50%;
  color: transparent;
  background: linear-gradient(135deg, var(--v281-accent), var(--v281-support));
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--v281-accent) 9%, transparent);
}

/* ---------- product-page route actions ---------- */

body.v281-site .v281-product-actions {
  margin-block-start: auto;
  padding-block-start: 1.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: .78rem 1rem;
  align-items: center;
}

body.v281-site .v281-product-actions .v281-product-detail {
  margin: 0;
}

body.v281-site .v281-product-compare {
  min-block-size: 2.75rem;
  padding-inline: .2rem;
  display: inline-flex;
  gap: .45rem;
  align-items: center;
  color: var(--v281-accent);
  font-size: .76rem;
  font-weight: 680;
  line-height: 1.3;
  text-decoration: none;
  border-block-end: 1px solid color-mix(in srgb, var(--v281-accent) 34%, transparent);
}

body.v281-site .v281-product-compare span {
  transition: transform 240ms var(--v281-ease);
}

body.v281-site .v281-product-compare:hover span {
  transform: translateY(3px);
}

/* ---------- decision hand-off ---------- */

body.v281-site:not(.home-v281) .v281-decision {
  inline-size: var(--v281-shell);
  margin: clamp(3.5rem, 7vw, 7rem) auto clamp(4.5rem, 8vw, 8rem);
  padding: clamp(1.7rem, 3vw, 2.65rem);
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, .85fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: end;
  border-block: 1px solid var(--v281-line-strong);
  background:
    linear-gradient(105deg, rgba(7, 90, 168, .045), rgba(8, 125, 89, .038) 70%, transparent),
    var(--v281-paper);
}

body.v281-site:not(.home-v281) .v281-decision__copy > span {
  display: block;
  margin-block-end: .72rem;
  color: var(--v281-accent);
  font-size: .63rem;
  font-weight: 780;
  letter-spacing: .16em;
}

body.v281-site:not(.home-v281) .v281-decision__copy > strong {
  max-inline-size: 23ch;
  display: block;
  color: var(--v281-ink);
  font-size: clamp(1.35rem, 2.25vw, 2.15rem);
  font-weight: 660;
  line-height: 1.15;
  letter-spacing: -.045em;
  text-wrap: balance;
}

body.v281-site:not(.home-v281) .v281-decision__copy > p {
  max-inline-size: 62ch;
  margin: .9rem 0 0;
  color: var(--v281-text);
  font-size: .82rem;
  line-height: 1.75;
}

body.v281-site:not(.home-v281) .v281-decision__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: .7rem;
}

body.v281-site:not(.home-v281) .v281-decision__action {
  min-block-size: 2.8rem;
  padding: .7rem .95rem;
  display: inline-flex;
  gap: .75rem;
  align-items: center;
  justify-content: space-between;
  color: var(--v281-ink);
  font-size: .74rem;
  font-weight: 680;
  line-height: 1.3;
  text-decoration: none;
  border: 1px solid var(--v281-line-strong);
  background: rgba(255, 255, 255, .68);
  transition:
    color 240ms var(--v281-ease),
    border-color 240ms var(--v281-ease),
    background-color 240ms var(--v281-ease),
    transform 240ms var(--v281-ease);
}

body.v281-site:not(.home-v281) .v281-decision__action:hover {
  border-color: color-mix(in srgb, var(--v281-accent) 46%, transparent);
  background: white;
  transform: translateY(-2px);
}

body.v281-site:not(.home-v281) .v281-decision__action.is-primary {
  color: white;
  border-color: transparent;
  background: linear-gradient(105deg, var(--v281-accent), color-mix(in srgb, var(--v281-accent) 74%, var(--v281-support)));
  box-shadow: 0 12px 28px color-mix(in srgb, var(--v281-accent) 17%, transparent);
}

body.v281-site:not(.home-v281) .v281-decision__action span {
  transition: transform 240ms var(--v281-ease);
}

body.v281-site:not(.home-v281) .v281-decision__action:hover span {
  transform: translate(2px, -2px);
}

/* Context-aware shared CTAs: current-page loops are converted to useful next steps. */
body.v281-site .formal-footer-cta [data-v281-rerouted="true"]::after {
  content: " ↗";
  font-size: .78em;
}

@media (max-width: 980px) {
  body.v281-site:not(.home-v281) .v281-path__inner {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  body.v281-site:not(.home-v281) .v281-path__intro {
    max-inline-size: 42ch;
  }

  body.v281-site:not(.home-v281) .v281-decision {
    grid-template-columns: 1fr;
    align-items: start;
  }

  body.v281-site:not(.home-v281) .v281-decision__actions {
    justify-content: flex-start;
  }
}

@media (max-width: 720px) {
  body.v281-site {
    --v281-shell: min(100% - 32px, 1180px);
  }

  body.v281-site:not(.home-v281) main :is(section, article, div)[id] {
    scroll-margin-top: 7.8rem;
  }

  body.v281-site:not(.home-v281) .v281-path {
    overflow: hidden;
  }

  body.v281-site:not(.home-v281) .v281-path__inner {
    inline-size: 100%;
    padding: 1.1rem 0 1.2rem;
    gap: .8rem;
  }

  body.v281-site:not(.home-v281) .v281-path__intro {
    inline-size: var(--v281-shell);
    margin-inline: auto;
  }

  body.v281-site:not(.home-v281) .v281-path__intro > span {
    font-size: .56rem;
  }

  body.v281-site:not(.home-v281) .v281-path__intro > strong {
    font-size: .86rem;
  }

  body.v281-site:not(.home-v281) .v281-path ol {
    inline-size: 100%;
    padding-inline: 16px;
    grid-template-columns: repeat(4, minmax(164px, 1fr));
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
  }

  body.v281-site:not(.home-v281) .v281-path ol::-webkit-scrollbar {
    display: none;
  }

  body.v281-site:not(.home-v281) .v281-path li {
    scroll-snap-align: start;
  }

  body.v281-site:not(.home-v281) .v281-path__item {
    min-block-size: 4.65rem;
    padding: .6rem .78rem;
    grid-template-columns: 1.55rem minmax(0, 1fr) auto;
  }

  body.v281-site:not(.home-v281) .v281-path__copy strong {
    font-size: .78rem;
  }

  body.v281-site:not(.home-v281) .v281-path__copy small {
    font-size: .62rem;
  }

  body.v281-site .v281-product-actions {
    align-items: stretch;
  }

  body.v281-site .v281-product-actions .v281-product-detail,
  body.v281-site .v281-product-compare {
    min-block-size: 2.9rem;
  }

  body.v281-site:not(.home-v281) .v281-decision {
    margin-block: 3.5rem 4.5rem;
    padding: 1.45rem 0;
    gap: 1.4rem;
    background: transparent;
  }

  body.v281-site:not(.home-v281) .v281-decision__copy > strong {
    font-size: clamp(1.25rem, 6.1vw, 1.7rem);
  }

  body.v281-site:not(.home-v281) .v281-decision__actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  body.v281-site:not(.home-v281) .v281-decision__action {
    min-block-size: 3rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.v281-site .v281-path__item,
  body.v281-site .v281-path__arrow,
  body.v281-site .v281-product-compare span,
  body.v281-site .v281-decision__action,
  body.v281-site .v281-decision__action span {
    transition-duration: .01ms !important;
    transform: none !important;
  }
}
