/* ==========================================================
   FMB REUSABLE TOOL PAGE SYSTEM
   Shortcode-driven sections shared by every individual Tool.
   ========================================================== */

.fmb-tool-page--shortcode-driven {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
  overflow: clip;
}

.fmb-tool-calculator-slot {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
  scroll-margin-top: 118px;
}

.fmb-tool-block {
  width: 100%;
  padding: clamp(46px, 5vw, 72px) var(--fmb-gutter);
}

.fmb-tool-block--white { background: var(--fmb-white); color: var(--fmb-heading); }
.fmb-tool-block--cream { background: var(--fmb-cream); color: var(--fmb-heading); }
.fmb-tool-block--navy {
  background: linear-gradient(135deg, var(--fmb-navy-dark) 0%, var(--fmb-navy) 65%, var(--fmb-navy-soft) 100%);
  color: var(--fmb-white);
}

.fmb-tool-block__shell {
  width: min(var(--fmb-editorial-shell), var(--fmb-editorial-shell-desktop));
  margin-inline: auto;
}

.fmb-tool-block__shell--reading { max-width: 900px; }
.fmb-tool-block__shell--wide { max-width: var(--fmb-editorial-shell); }

.fmb-tool-block__heading {
  max-width: var(--fmb-editorial-heading-max);
  margin: 0 0 clamp(26px, 3vw, 38px);
}

.fmb-tool-block__eyebrow,
.fmb-tool-hero__eyebrow,
.fmb-tool-card__kicker {
  margin: 0 0 12px;
  color: var(--fmb-gold-text);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .17em;
  line-height: 1.25;
  text-transform: uppercase;
}

.fmb-tool-block--navy .fmb-tool-block__eyebrow,
.fmb-tool-block--navy .fmb-tool-card__kicker { color: var(--fmb-gold); }

.fmb-tool-block__heading h2,
.fmb-tool-callout h2 {
  margin: 0;
  color: inherit;
  font-family: var(--fmb-font-display);
  font-size: clamp(31px, 3.1vw, 45px);
  font-weight: 800;
  letter-spacing: -.025em;
  line-height: 1.08;
}

.fmb-tool-block__highlight { color: var(--fmb-gold-dark); }
.fmb-tool-block--navy .fmb-tool-block__highlight,
.fmb-tool-hero .fmb-tool-block__highlight { color: var(--fmb-gold); }

.fmb-tool-block__description,
.fmb-tool-block__copy,
.fmb-tool-block__prose,
.fmb-tool-callout__copy,
.fmb-tool-methodology__copy {
  color: var(--fmb-body);
  font-size: 17px;
  line-height: 1.7;
}

.fmb-tool-block__description {
  max-width: 820px;
  margin-top: 16px;
}

.fmb-tool-block__description > :first-child,
.fmb-tool-block__copy > :first-child,
.fmb-tool-block__prose > :first-child,
.fmb-tool-callout__copy > :first-child,
.fmb-tool-methodology__copy > :first-child { margin-top: 0; }
.fmb-tool-block__description > :last-child,
.fmb-tool-block__copy > :last-child,
.fmb-tool-block__prose > :last-child,
.fmb-tool-callout__copy > :last-child,
.fmb-tool-methodology__copy > :last-child { margin-bottom: 0; }

.fmb-tool-block--navy .fmb-tool-block__description,
.fmb-tool-block--navy .fmb-tool-block__copy,
.fmb-tool-block--navy .fmb-tool-block__prose,
.fmb-tool-block--navy .fmb-tool-callout__copy,
.fmb-tool-block--navy .fmb-tool-methodology__copy { color: rgba(255,255,255,.78); }

/* Hero */
.fmb-tool-hero {
  position: relative;
  isolation: isolate;
  width: 100%;
  overflow: hidden;
  border-top: 1px solid rgba(212, 182, 120, .28);
  background: linear-gradient(135deg, var(--fmb-navy-dark) 0%, var(--fmb-navy) 62%, #0a2038 100%);
  color: var(--fmb-white);
}

.fmb-tool-hero::after {
  position: absolute;
  z-index: -1;
  right: -16vw;
  bottom: -28vw;
  width: 60vw;
  height: 60vw;
  border: 1px solid rgba(212, 182, 120, .08);
  border-radius: 50%;
  content: "";
}

.fmb-tool-hero__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  width: min(var(--fmb-editorial-shell), var(--fmb-editorial-shell-desktop));
  min-height: clamp(390px, 42vw, 520px);
  margin-inline: auto;
  align-items: center;
}

.fmb-tool-hero--with-image .fmb-tool-hero__inner {
  grid-template-columns: minmax(0, 1.12fr) minmax(360px, .88fr);
  gap: clamp(34px, 5vw, 76px);
}

.fmb-tool-hero__content { max-width: 860px; padding: clamp(54px, 6vw, 88px) 0; }
.fmb-tool-hero__eyebrow { color: var(--fmb-gold); }
.fmb-tool-hero h1 {
  max-width: 920px;
  margin: 0;
  color: var(--fmb-white);
  font-family: var(--fmb-font-display);
  font-size: clamp(42px, 5.2vw, 72px);
  font-weight: 800;
  letter-spacing: -.035em;
  line-height: .99;
}

.fmb-tool-hero__description {
  max-width: 760px;
  margin-top: 20px;
  color: rgba(255,255,255,.78);
  font-size: clamp(17px, 1.4vw, 19px);
  line-height: 1.65;
}
.fmb-tool-hero__description > :first-child { margin-top: 0; }
.fmb-tool-hero__description > :last-child { margin-bottom: 0; }

.fmb-tool-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 25px;
}
.fmb-tool-hero__meta span {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  padding: 6px 11px;
  border: 1px solid rgba(212,182,120,.35);
  border-radius: var(--fmb-radius-pill);
  background: rgba(255,255,255,.04);
  color: rgba(255,255,255,.82);
  font-size: 12px;
  font-weight: 700;
}

.fmb-tool-hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
  margin-top: 30px;
}
.fmb-tool-hero__secondary {
  color: var(--fmb-white);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}
.fmb-tool-hero__secondary span { display: inline-block; margin-left: 6px; transition: transform var(--fmb-transition); }
.fmb-tool-hero__secondary:hover { color: var(--fmb-gold); }
.fmb-tool-hero__secondary:hover span { transform: translateX(4px); }

.fmb-tool-hero__media {
  align-self: stretch;
  min-height: 360px;
  margin: 0;
  overflow: hidden;
}
.fmb-tool-hero__media img {
  width: 100%;
  height: 100%;
  min-height: 100%;
  object-fit: cover;
}

/* Intro and prose */
.fmb-tool-intro--center .fmb-tool-block__heading,
.fmb-tool-intro--center .fmb-tool-block__copy { margin-inline: auto; text-align: center; }
.fmb-tool-block__copy { max-width: 900px; font-size: 18px; }
.fmb-tool-block__prose { font-size: 17px; }
.fmb-tool-block__prose h3 { margin: 32px 0 10px; color: inherit; font-family: var(--fmb-font-display); font-size: 26px; line-height: 1.15; }
.fmb-tool-block__prose a { color: var(--fmb-gold-text); font-weight: 700; text-underline-offset: 3px; }
.fmb-tool-block--navy .fmb-tool-block__prose a { color: var(--fmb-gold); }

/* Cards */
.fmb-tool-cards__grid {
  display: grid;
  gap: clamp(16px, 1.6vw, 24px);
}
.fmb-tool-cards__grid--2 { grid-template-columns: repeat(2, minmax(0,1fr)); }
.fmb-tool-cards__grid--3 { grid-template-columns: repeat(3, minmax(0,1fr)); }
.fmb-tool-cards__grid--4 { grid-template-columns: repeat(4, minmax(0,1fr)); }
.fmb-tool-card {
  min-width: 0;
  padding: clamp(23px, 2.4vw, 32px);
  border: 1px solid var(--fmb-editorial-border);
  border-radius: var(--fmb-radius-md);
  background: var(--fmb-white);
  box-shadow: 0 10px 28px rgba(7,24,47,.04);
  transition: transform var(--fmb-transition), border-color var(--fmb-transition), box-shadow var(--fmb-transition);
}
.fmb-tool-card:hover {
  transform: translateY(-3px);
  border-color: rgba(168,130,58,.48);
  box-shadow: var(--fmb-shadow-sm);
}
.fmb-tool-block--navy .fmb-tool-card {
  border-color: rgba(255,255,255,.13);
  background: rgba(255,255,255,.055);
  box-shadow: none;
}
.fmb-tool-block--navy .fmb-tool-card:hover { border-color: rgba(212,182,120,.58); }
.fmb-tool-card__icon,
.fmb-tool-related__icon {
  display: inline-grid;
  width: 44px;
  height: 44px;
  margin-bottom: 22px;
  place-items: center;
  border: 1px solid rgba(168,130,58,.28);
  border-radius: 50%;
  background: rgba(212,182,120,.12);
  color: var(--fmb-gold-dark);
}
.fmb-tool-card__icon svg,
.fmb-tool-related__icon svg { width: 21px; height: 21px; fill: currentColor; }
.fmb-tool-card h3,
.fmb-tool-step h3,
.fmb-tool-split__panel h3,
.fmb-tool-related__card h3 {
  margin: 0;
  color: inherit;
  font-family: var(--fmb-font-display);
  font-size: clamp(22px, 2vw, 27px);
  line-height: 1.14;
}
.fmb-tool-card p:not(.fmb-tool-card__kicker),
.fmb-tool-step p,
.fmb-tool-split__panel p,
.fmb-tool-related__card p {
  margin: 11px 0 0;
  color: var(--fmb-body);
  font-size: 15.5px;
  line-height: 1.65;
}
.fmb-tool-block--navy .fmb-tool-card p:not(.fmb-tool-card__kicker),
.fmb-tool-block--navy .fmb-tool-step p,
.fmb-tool-block--navy .fmb-tool-split__panel p,
.fmb-tool-block--navy .fmb-tool-related__card p { color: rgba(255,255,255,.72); }

/* Steps */
.fmb-tool-steps__grid { display: grid; gap: 0; border-top: 1px solid var(--fmb-editorial-border); }
.fmb-tool-step {
  display: grid;
  grid-template-columns: 64px minmax(0,1fr);
  gap: 22px;
  padding: 26px 0;
  border-bottom: 1px solid var(--fmb-editorial-border);
}
.fmb-tool-step__number {
  color: var(--fmb-gold-dark);
  font-family: var(--fmb-font-display);
  font-size: 24px;
  font-weight: 800;
}
.fmb-tool-block--navy .fmb-tool-steps__grid,
.fmb-tool-block--navy .fmb-tool-step { border-color: rgba(255,255,255,.13); }
.fmb-tool-block--navy .fmb-tool-step__number { color: var(--fmb-gold); }

/* Split */
.fmb-tool-split__grid {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: clamp(18px, 2vw, 28px);
}
.fmb-tool-split__panel {
  padding: clamp(26px, 3vw, 38px);
  border: 1px solid var(--fmb-editorial-border);
  border-top: 3px solid var(--fmb-gold-dark);
  border-radius: var(--fmb-radius-md);
  background: var(--fmb-white);
}
.fmb-tool-block--navy .fmb-tool-split__panel {
  border-color: rgba(255,255,255,.13);
  border-top-color: var(--fmb-gold);
  background: rgba(255,255,255,.055);
}
.fmb-tool-split__panel ul {
  display: grid;
  gap: 9px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}
.fmb-tool-split__panel li {
  position: relative;
  padding-left: 22px;
  color: var(--fmb-body);
  font-size: 15px;
  line-height: 1.55;
}
.fmb-tool-split__panel li::before {
  position: absolute;
  top: .65em;
  left: 0;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--fmb-gold-dark);
  content: "";
}
.fmb-tool-block--navy .fmb-tool-split__panel li { color: rgba(255,255,255,.74); }
.fmb-tool-block--navy .fmb-tool-split__panel li::before { background: var(--fmb-gold); }

/* Callout */
.fmb-tool-callout__inner {
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  gap: 36px;
  align-items: center;
  padding: clamp(28px, 3.5vw, 46px);
  border: 1px solid rgba(212,182,120,.28);
  border-left: 4px solid var(--fmb-gold);
  border-radius: var(--fmb-radius-md);
  background: rgba(255,255,255,.035);
}
.fmb-tool-block--white .fmb-tool-callout__inner,
.fmb-tool-block--cream .fmb-tool-callout__inner {
  border-color: var(--fmb-editorial-border);
  border-left-color: var(--fmb-gold-dark);
  background: var(--fmb-white);
}
.fmb-tool-callout h2 { max-width: 900px; font-size: clamp(30px, 3vw, 43px); }
.fmb-tool-callout__copy { max-width: 850px; margin-top: 14px; }

/* Methodology */
.fmb-tool-methodology__grid {
  display: grid;
  grid-template-columns: minmax(0,.8fr) minmax(0,1.2fr);
  gap: clamp(34px, 6vw, 86px);
  align-items: start;
}
.fmb-tool-methodology .fmb-tool-block__heading { margin-bottom: 0; }
.fmb-tool-methodology__copy { padding-top: 4px; }
.fmb-tool-methodology__links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 26px;
  margin-top: 24px !important;
}
.fmb-tool-methodology__links a {
  color: var(--fmb-navy);
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
}
.fmb-tool-methodology__links a:hover { color: var(--fmb-gold-dark); }
.fmb-tool-block--navy .fmb-tool-methodology__links a { color: var(--fmb-gold); }

/* Related tools */
.fmb-tool-related__grid {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: clamp(16px,1.6vw,24px);
}
.fmb-tool-related__card {
  display: flex;
  min-width: 0;
  min-height: 100%;
  flex-direction: column;
  padding: clamp(23px,2.4vw,30px);
  border: 1px solid var(--fmb-editorial-border);
  border-radius: var(--fmb-radius-md);
  background: var(--fmb-white);
  transition: transform var(--fmb-transition), border-color var(--fmb-transition), box-shadow var(--fmb-transition);
}
.fmb-tool-related__card:hover { transform: translateY(-3px); border-color: rgba(168,130,58,.5); box-shadow: var(--fmb-shadow-sm); }
.fmb-tool-related__top { display:flex; align-items:center; justify-content:space-between; gap:14px; margin-bottom:22px; }
.fmb-tool-related__top .fmb-tool-related__icon { margin:0; }
.fmb-tool-related__top > span:last-child { color: var(--fmb-muted); font-size:12px; font-weight:700; }
.fmb-tool-related__action {
  display: flex;
  min-height: 46px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding: 12px 14px;
  border: 1px solid var(--fmb-gold-dark);
  border-radius: var(--fmb-radius-sm);
  color: var(--fmb-navy);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  transition: background-color var(--fmb-transition), border-color var(--fmb-transition), transform var(--fmb-transition);
}
.fmb-tool-related__card p + .fmb-tool-related__action { margin-top: 24px; }
.fmb-tool-related__action span { transition: transform var(--fmb-transition); }
.fmb-tool-related__action:hover { transform: translateY(-1px); border-color: var(--fmb-gold); background: var(--fmb-gold); }
.fmb-tool-related__action:hover span { transform: translateX(4px); }

@media (max-width: 1100px) {
  .fmb-tool-hero--with-image .fmb-tool-hero__inner { grid-template-columns: minmax(0,1fr) minmax(300px,.72fr); gap: 34px; }
  .fmb-tool-cards__grid--4 { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .fmb-tool-related__grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

@media (max-width: 820px) {
  .fmb-tool-hero--with-image .fmb-tool-hero__inner { grid-template-columns: 1fr; width: 100%; }
  .fmb-tool-hero--with-image .fmb-tool-hero__content { width: min(var(--fmb-editorial-shell), var(--fmb-editorial-shell-desktop)); margin-inline:auto; padding-bottom: 36px; }
  .fmb-tool-hero__media { min-height: 290px; max-height: 420px; }
  .fmb-tool-split__grid,
  .fmb-tool-methodology__grid { grid-template-columns: 1fr; }
  .fmb-tool-callout__inner { grid-template-columns: 1fr; }
  .fmb-tool-methodology__grid { gap: 24px; }
}

@media (max-width: 680px) {
  .fmb-tool-block { padding: 40px 20px; }
  .fmb-tool-block__shell,
  .fmb-tool-hero__inner { width: 100%; }
  .fmb-tool-hero__content { padding: 50px 20px; }
  .fmb-tool-hero--with-image .fmb-tool-hero__content { width:100%; padding:50px 20px 32px; }
  .fmb-tool-hero h1 { font-size: clamp(38px,12vw,52px); }
  .fmb-tool-cards__grid--2,
  .fmb-tool-cards__grid--3,
  .fmb-tool-cards__grid--4,
  .fmb-tool-related__grid { grid-template-columns: 1fr; }
  .fmb-tool-step { grid-template-columns: 48px minmax(0,1fr); gap: 14px; }
  .fmb-tool-hero__actions { align-items: stretch; flex-direction: column; }
  .fmb-tool-hero__actions .fmb-button { width: 100%; }
}
