/* FOXES – PLAN CALCULATOR styles
 * v3: rebranded per foxes.es brand guide.
 *   - Geist font throughout (sans-serif only)
 *   - Brand red (#D05050) as primary accent
 *   - Ink (#0C0C0C) for text and dark feature surfaces
 *   - Cream (#FAF6EE) for soft surfaces, white for cards
 *   - Rule (#E8DECC) for borders and dividers
 * Inner element IDs (fbg-country, fbg-results, etc.) retain their
 * fbg- prefix as before. They are already calc-specific and will not
 * collide with the other Foxes calculators (mortgage/eligibility/FAQ).
 */

#foxes-plan-calculator-mount,
#foxes-plan-calculator-mount *,
#foxes-plan-calculator-mount *::before,
#foxes-plan-calculator-mount *::after { box-sizing: border-box; }

#foxes-plan-calculator-mount {
  /* Foxes brand tokens (source of truth) */
  --fx-red:       #D05050;
  --fx-red-dark:  #C04545;
  --fx-red-soft:  #F7E0E0;
  --fx-ink:       #0C0C0C;
  --fx-ink-soft:  #1F1F1F;
  --fx-cream:     #FAF6EE;
  --fx-white:     #FFFFFF;
  --fx-rule:      #E8DECC;
  --fx-rule-soft: #F2EBDD;
  --fx-gold:      #C8A24A;

  /* Functional aliases (legacy names kept so the JS, which references
     var(--ink) / var(--line-l) directly in inline styles, keeps working) */
  --brand:    var(--fx-red);
  --brand-d:  var(--fx-red-dark);
  --brand-dd: var(--fx-red-dark);
  --brand-l:  var(--fx-red-soft);
  --brand-ll: var(--fx-cream);
  --brand-b:  #EFD3D3;
  --ink:      var(--fx-ink);
  --ink-2:    #2A2A2A;
  --ink-3:    #555555;
  --ink-4:    #888888;
  --line:     var(--fx-rule);
  --line-l:   var(--fx-rule-soft);
  --bg:       var(--fx-cream);
  --card:     var(--fx-white);
  --green:    #1F7A4A;
  --green-l:  #E6F3EC;
  --amber:    #92600A;
  --amber-l:  #FEF3DC;

  /* Geometry (brand spec: buttons/inputs 10px, cards 16px, badges pill) */
  --r:    16px;
  --r-sm: 10px;
  --r-xs: 8px;

  /* Dark feature gradient, reused on panel head, hero overlay, card heads */
  --fx-dark-grad: linear-gradient(155deg, var(--fx-ink) 0%, var(--fx-ink-soft) 100%);

  font-family: 'Geist', sans-serif;
  color: var(--fx-ink);
  max-width: 1200px;
  margin: 0 auto;
  font-feature-settings: 'ss01', 'cv01';
}

/* ── INPUT PANEL ────────────────────────────────────────────────────────── */
#foxes-plan-calculator-mount .fbg-panel{
  background: var(--fx-white);
  border: 1px solid var(--fx-rule);
  border-radius: var(--r);
  overflow: hidden;
  margin-bottom: 24px;
}
#foxes-plan-calculator-mount .fbg-panel-head{
  background: var(--fx-dark-grad);
  padding: 28px 32px 24px;
  color: var(--fx-white);
}
#foxes-plan-calculator-mount .fbg-panel-head h1{
  font-family: 'Geist', sans-serif;
  font-size: 26px;
  font-weight: 600;
  margin: 0 0 4px;
  line-height: 1.15;
  letter-spacing: -0.015em;
  color: var(--fx-white) !important;
}
#foxes-plan-calculator-mount .fbg-panel-head p{
  margin: 0;
  font-size: 15px;
  opacity: 0.82;
  line-height: 1.5;
  color: var(--fx-white) !important;
}
#foxes-plan-calculator-mount .fbg-panel-body{ padding: 24px 32px 28px; }

#foxes-plan-calculator-mount .fbg-fields{
  display: grid;
  grid-template-columns: 1.15fr 1fr 1fr 1fr;
  gap: 14px;
  align-items: start;
}
#foxes-plan-calculator-mount .fbg-label{
  display: block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0 0 7px 2px;
}
#foxes-plan-calculator-mount .fbg-select,
#foxes-plan-calculator-mount .fbg-input{
  width: 100%;
  height: 50px;
  border: 1px solid var(--fx-rule);
  border-radius: var(--r-sm);
  padding: 0 14px;
  font-size: 15px;
  font-family: 'Geist', sans-serif;
  color: var(--fx-ink);
  background: var(--fx-white);
  outline: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
  appearance: auto;
}
#foxes-plan-calculator-mount .fbg-select:hover,
#foxes-plan-calculator-mount .fbg-input:hover{ border-color: #D8C9A8; }
#foxes-plan-calculator-mount .fbg-select:focus,
#foxes-plan-calculator-mount .fbg-input:focus{
  border-color: var(--fx-red);
  box-shadow: 0 0 0 3px var(--fx-red-soft);
}
#foxes-plan-calculator-mount .fbg-input.err{
  border-color: var(--fx-red-dark);
  box-shadow: 0 0 0 3px var(--fx-red-soft);
}
#foxes-plan-calculator-mount .fbg-hint{
  font-size: 12px;
  margin: 4px 0 0 2px;
  color: var(--ink-4);
  line-height: 1.3;
}
#foxes-plan-calculator-mount .fbg-hint:empty{ display: none; }
#foxes-plan-calculator-mount .fbg-hint.err{ color: var(--fx-red-dark); font-weight: 600; }

#foxes-plan-calculator-mount .fbg-panel-footer{
  border-top: 1px solid var(--fx-rule);
  padding: 14px 32px;
  background: var(--fx-cream);
  display: flex;
  align-items: center;
  gap: 10px;
}
#foxes-plan-calculator-mount .fbg-panel-footer-dot{
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--fx-red); flex-shrink: 0;
}
#foxes-plan-calculator-mount .fbg-panel-footer p{
  margin: 0;
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.5;
}

/* ── RESULTS ───────────────────────────────────────────────────────────── */
#foxes-plan-calculator-mount .fbg-results{ display: grid; gap: 20px; }

/* empty / error */
/* Placeholder background is white (not cream) so it stands out against
   the site's cream page background. Dashed border kept as the standard
   "empty / waiting" convention. */
#foxes-plan-calculator-mount .fbg-placeholder{
  border: 1.5px dashed #D8C9A8;
  border-radius: var(--r);
  padding: 48px 24px;
  text-align: center;
  background: var(--fx-white);
}
#foxes-plan-calculator-mount .fbg-placeholder-icon{
  font-size: 40px; opacity: 0.25; margin-bottom: 12px;
}
#foxes-plan-calculator-mount .fbg-placeholder h3{
  margin: 0 0 8px;
  font-family: 'Geist', sans-serif;
  font-size: 18px; font-weight: 600;
  color: var(--fx-ink);
  letter-spacing: -0.005em;
}
#foxes-plan-calculator-mount .fbg-placeholder p{
  margin: 0 auto;
  font-size: 14px;
  color: var(--ink-3);
  line-height: 1.6;
  max-width: 380px;
}
#foxes-plan-calculator-mount .fbg-err-banner{
  background: var(--fx-red-soft);
  border-radius: var(--r);
  padding: 20px 24px;
  display: flex; align-items: flex-start; gap: 14px;
}
#foxes-plan-calculator-mount .fbg-err-banner-icon{
  font-size: 20px; flex-shrink: 0; margin-top: 1px;
  color: var(--fx-red-dark);
}
#foxes-plan-calculator-mount .fbg-err-banner h4{
  margin: 0 0 4px;
  font-family: 'Geist', sans-serif;
  font-size: 15px; font-weight: 600;
  color: var(--fx-red-dark);
}
#foxes-plan-calculator-mount .fbg-err-banner p{
  margin: 0;
  font-size: 14px;
  color: var(--fx-ink);
  line-height: 1.6;
}

/* ── HERO ──────────────────────────────────────────────────────────────── */
/* The JS sets hero.style.backgroundImage when a region is selected, which
   replaces the gradient image set in CSS. We declare background-color and
   background-image SEPARATELY (not via the `background` shorthand) so the
   dark fallback colour persists even if the region photo fails to load,
   is blocked, or has not yet loaded. The .fbg-hero-overlay layer sits
   over any backdrop to keep text readable. */
#foxes-plan-calculator-mount .fbg-hero{
  position: relative;
  border-radius: var(--r);
  padding: 28px 28px 24px;
  color: var(--fx-white);
  overflow: hidden;
  background-color: var(--fx-ink-soft);
  background-image: var(--fx-dark-grad);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
#foxes-plan-calculator-mount .fbg-hero-overlay{
  position: absolute;
  inset: 0;
  display: block;
  /* Vertical fade tuned for the actual text layout. The eyebrow, pill,
     h2 AND sub paragraph all stack in the top half, so we hold a strong
     dark band from 0% to ~55% before easing slightly through the middle
     and re-darkening for the stats grid. Tuned so text reads cleanly
     even on bright photos (e.g. Balearic sunset). */
  background: linear-gradient(
    180deg,
    rgba(12, 12, 12, 0.85) 0%,
    rgba(12, 12, 12, 0.78) 30%,
    rgba(12, 12, 12, 0.65) 55%,
    rgba(12, 12, 12, 0.72) 75%,
    rgba(12, 12, 12, 0.92) 100%
  );
  pointer-events: none;
}
#foxes-plan-calculator-mount .fbg-hero > *{ position: relative; z-index: 1; }

/* Glass-card backdrop behind the upper hero text (eyebrow + pill + h2
   + sub paragraph). Matches the .fbg-stat treatment below so the hero
   reads as two stacked translucent panels over the region photo. */
#foxes-plan-calculator-mount .fbg-hero-card{
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  padding: 18px 22px 20px;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}
#foxes-plan-calculator-mount .fbg-hero-card .fbg-hero-head{
  /* Inside the card the head row no longer needs its own bottom margin
     for h2 separation, but a small gap reads cleaner */
  margin-bottom: 10px;
}
#foxes-plan-calculator-mount .fbg-hero-card h2{
  margin-bottom: 8px;
}
#foxes-plan-calculator-mount .fbg-hero-card .fbg-hero-sub{
  margin-bottom: 0;
}

#foxes-plan-calculator-mount .fbg-hero-head{
  display: flex; flex-wrap: wrap; gap: 10px;
  align-items: center; justify-content: space-between;
  margin-bottom: 12px;
}
#foxes-plan-calculator-mount .fbg-eyebrow{
  font-family: 'Geist', sans-serif;
  font-size: 11px; font-weight: 600;
  opacity: 0.7;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--fx-white) !important;
}
#foxes-plan-calculator-mount .fbg-pill{
  display: inline-flex; align-items: center;
  padding: 5px 14px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.12) !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  font-family: 'Geist', sans-serif;
  font-size: 12px; font-weight: 600;
  white-space: nowrap;
  color: var(--fx-white) !important;
}
#foxes-plan-calculator-mount .fbg-hero h2{
  font-family: 'Geist', sans-serif;
  font-size: 24px; font-weight: 600;
  margin: 0 0 6px;
  letter-spacing: -0.015em; line-height: 1.15;
  color: var(--fx-white) !important;
}
#foxes-plan-calculator-mount .fbg-hero-sub{
  margin: 0;
  font-size: 14px; opacity: 0.85;
  line-height: 1.55;
  color: var(--fx-white) !important;
}

#foxes-plan-calculator-mount .fbg-stats{
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 10px; margin-top: 22px;
}
#foxes-plan-calculator-mount .fbg-stat{
  /* Dark semi-opaque backdrop so the box reads as a discrete element
     and the values stay legible over any region photo. */
  background: rgba(0, 0, 0, 0.4) !important;
  border: 1px solid rgba(255, 255, 255, 0.18) !important;
  border-radius: 12px;
  padding: 14px 16px;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}
#foxes-plan-calculator-mount .fbg-stat-l{
  font-family: 'Geist', sans-serif;
  font-size: 10px; font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  opacity: 0.68;
  margin-bottom: 6px;
  color: var(--fx-white) !important;
}
#foxes-plan-calculator-mount .fbg-stat-v{
  font-family: 'Geist', sans-serif;
  font-size: 18px; font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--fx-white) !important;
}

/* ── EDITABLE STATS (Mortgage / Deposit) ──────────────────────────────────
   The values become contenteditable on focus. A subtle dashed underline
   on the editable cells signals interactivity without competing with the
   value itself. Focus state turns the underline red and adds a faint
   highlight to confirm edit mode. */
#foxes-plan-calculator-mount .fbg-stat-edit .fbg-edit{
  cursor: text;
  outline: none;
  display: inline-block;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.28);
  padding: 0 2px 2px;
  margin: 0 -2px;
  border-radius: 2px;
  transition: border-color 150ms ease, background 150ms ease;
  /* Strip any user-agent styling on contenteditable */
  -webkit-user-select: text;
  user-select: text;
}
#foxes-plan-calculator-mount .fbg-stat-edit .fbg-edit:hover{
  border-bottom-color: rgba(255, 255, 255, 0.6);
}
#foxes-plan-calculator-mount .fbg-stat-edit .fbg-edit:focus{
  border-bottom: 1px solid var(--fx-red);
  background: rgba(255, 255, 255, 0.06);
}
/* Subtitle showing LTV % below the editable value */
#foxes-plan-calculator-mount .fbg-stat-sub{
  font-family: 'Geist', sans-serif;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fx-white) !important;
  opacity: 0.55;
  margin-top: 6px;
  line-height: 1.2;
}
/* Reset link inside the subtitle: visible enough to find, not loud */
#foxes-plan-calculator-mount .fbg-reset-ltv{
  color: var(--fx-white) !important;
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, 0.45);
  text-underline-offset: 2px;
  opacity: 0.95;
  transition: text-decoration-color 150ms ease;
}
#foxes-plan-calculator-mount .fbg-reset-ltv:hover{
  text-decoration-color: var(--fx-white);
}

/* ── SECTION DIVIDER ───────────────────────────────────────────────────── */
#foxes-plan-calculator-mount .fbg-section{
  display: flex; align-items: center; gap: 14px;
  margin: 4px 0 0;
}
#foxes-plan-calculator-mount .fbg-section-label{
  font-family: 'Geist', sans-serif;
  font-size: 11px; font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-2);
  white-space: nowrap;
}
#foxes-plan-calculator-mount .fbg-section-line{
  height: 1px; background: var(--fx-rule); flex: 1;
}

/* ── CARDS ─────────────────────────────────────────────────────────────── */
#foxes-plan-calculator-mount .fbg-card{
  background: var(--fx-white);
  border: 1px solid var(--fx-rule);
  border-radius: var(--r);
  overflow: hidden;
}
#foxes-plan-calculator-mount .fbg-card-hd{
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px;
  padding: 14px 24px;
  background: var(--fx-dark-grad);
  border-radius: var(--r) var(--r) 0 0;
}
/* The .fin/.teal/.green/.navy modifiers exist in the JS for semantic
   reasons (mortgage/healthcare/costs/regional). In the rebrand they
   share the same dark ink feature gradient, differentiation comes
   from the icon. Modifiers retained for any future variation. */
#foxes-plan-calculator-mount .fbg-card-hd.fin,
#foxes-plan-calculator-mount .fbg-card-hd.teal,
#foxes-plan-calculator-mount .fbg-card-hd.green,
#foxes-plan-calculator-mount .fbg-card-hd.navy{
  background: var(--fx-dark-grad);
}
#foxes-plan-calculator-mount .fbg-card-hd h3{
  margin: 0;
  font-family: 'Geist', sans-serif;
  font-size: 15px; font-weight: 600;
  color: var(--fx-white) !important;
  letter-spacing: -0.005em;
}
#foxes-plan-calculator-mount .fbg-card-bd{ padding: 20px 24px; }
#foxes-plan-calculator-mount .fbg-badge{
  display: inline-block;
  padding: 3px 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: var(--fx-white);
  font-family: 'Geist', sans-serif;
  font-size: 11px; font-weight: 600;
  letter-spacing: 0.02em;
  white-space: nowrap; flex-shrink: 0;
}
#foxes-plan-calculator-mount .fbg-badge.green,
#foxes-plan-calculator-mount .fbg-badge.amber{
  background: rgba(255, 255, 255, 0.14);
  color: var(--fx-white);
}

/* ── TWO-COL GRID ──────────────────────────────────────────────────────── */
#foxes-plan-calculator-mount .fbg-2{
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px;
}

/* ── NARRATIVE / BODY TEXT ─────────────────────────────────────────────── */
#foxes-plan-calculator-mount .fbg-narrative{
  font-family: 'Geist', sans-serif;
  font-size: 15px; line-height: 1.7;
  color: var(--ink-2);
}
#foxes-plan-calculator-mount .fbg-narrative p{ margin: 0 0 14px !important; }
#foxes-plan-calculator-mount .fbg-narrative p:last-child{ margin: 0 !important; }

#foxes-plan-calculator-mount .fbg-body{
  font-family: 'Geist', sans-serif;
  font-size: 15px; line-height: 1.7;
  color: var(--ink-2);
}
#foxes-plan-calculator-mount .fbg-body p{ margin: 0 0 14px !important; }
#foxes-plan-calculator-mount .fbg-body p:last-child{ margin: 0 !important; }
#foxes-plan-calculator-mount .fbg-dblock .fbg-body{ color: var(--ink-2); }

/* ── DOC LIST ──────────────────────────────────────────────────────────── */
#foxes-plan-calculator-mount .fbg-doclist{
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: 9px;
}
#foxes-plan-calculator-mount .fbg-doclist li{
  position: relative; padding-left: 18px;
  font-size: 14px; line-height: 1.5;
  color: var(--ink-2);
}
#foxes-plan-calculator-mount .fbg-doclist li::before{
  content: "";
  position: absolute; left: 0; top: 0.56em;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--fx-red);
}

/* ── DATA BLOCKS (light + highlight) ───────────────────────────────────── */
#foxes-plan-calculator-mount .fbg-dblock{
  background: var(--fx-cream);
  border: 1px solid var(--fx-rule);
  border-radius: var(--r-sm);
  padding: 18px;
}
#foxes-plan-calculator-mount .fbg-dblock-title{
  font-family: 'Geist', sans-serif;
  font-size: 11px; font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-3);
  margin: 0 0 14px;
}
/* hblock = highlighted callout. Cream surface with a red top accent
   stripe and a red-dark title, used for the mortgage rate examples
   (Fixed at X% / Variable at X%) and the purchase tax breakdowns. Sits
   alongside the dark feature gradient on card heads as the "light"
   counterpart in the same brand vocabulary. */
#foxes-plan-calculator-mount .fbg-hblock{
  background: var(--fx-cream);
  border: 1px solid var(--fx-rule);
  border-top: 3px solid var(--fx-red);
  border-radius: var(--r-sm);
  padding: 18px;
}
#foxes-plan-calculator-mount .fbg-hblock-title{
  font-family: 'Geist', sans-serif;
  font-size: 11px; font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--fx-red-dark);
  margin: 0 0 14px;
}
#foxes-plan-calculator-mount .fbg-rows{ display: grid; gap: 0; }
#foxes-plan-calculator-mount .fbg-row{
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 12px; padding: 10px 0;
}
#foxes-plan-calculator-mount .fbg-row:first-child{ padding-top: 0; }
#foxes-plan-calculator-mount .fbg-dblock .fbg-row{ border-bottom: 1px solid var(--fx-rule); }
#foxes-plan-calculator-mount .fbg-dblock .fbg-row:last-child{ border-bottom: none; padding-bottom: 0; }
#foxes-plan-calculator-mount .fbg-hblock .fbg-row{ border-bottom: 1px solid var(--fx-rule); }
#foxes-plan-calculator-mount .fbg-hblock .fbg-row:last-child{ border-bottom: none; padding-bottom: 0; }
#foxes-plan-calculator-mount .fbg-row-l{
  font-size: 13px; line-height: 1.4; flex: 1 1 auto;
}
#foxes-plan-calculator-mount .fbg-dblock .fbg-row-l{ color: var(--ink-2); }
#foxes-plan-calculator-mount .fbg-hblock .fbg-row-l{ color: var(--ink-2); }
#foxes-plan-calculator-mount .fbg-row-v{
  font-family: 'Geist', sans-serif;
  font-size: 14px; font-weight: 600;
  text-align: right;
  flex: 0 0 auto; white-space: nowrap;
  letter-spacing: -0.005em;
}
#foxes-plan-calculator-mount .fbg-dblock .fbg-row-v{ color: var(--fx-ink); }
#foxes-plan-calculator-mount .fbg-hblock .fbg-row-v{ color: var(--fx-ink); }

/* ── BIG STAT ROWS ─────────────────────────────────────────────────────── */
#foxes-plan-calculator-mount .fbg-bigrow{
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 14px 0;
  border-bottom: 1px solid var(--fx-rule-soft);
}
#foxes-plan-calculator-mount .fbg-bigrow:last-child{ border-bottom: none; padding-bottom: 0; }
#foxes-plan-calculator-mount .fbg-bigrow:first-child{ padding-top: 0; }
#foxes-plan-calculator-mount .fbg-bigrow-l{
  font-size: 13px; color: var(--ink-3); flex: 1;
}
#foxes-plan-calculator-mount .fbg-bigrow-v{
  font-family: 'Geist', sans-serif;
  font-size: 18px; font-weight: 600;
  color: var(--fx-ink);
  text-align: right;
  letter-spacing: -0.01em;
}
#foxes-plan-calculator-mount .fbg-bigrow-v.brand{ color: var(--fx-red); }

/* ── TOGGLES (sit on dark term bar / card heads) ───────────────────────── */
#foxes-plan-calculator-mount .fbg-toggle{
  display: inline-flex;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  overflow: hidden;
  flex-shrink: 0;
}
#foxes-plan-calculator-mount .fbg-tbtn{
  padding: 6px 16px;
  font-family: 'Geist', sans-serif;
  font-size: 12px; font-weight: 600;
  border: none; background: transparent;
  color: rgba(255, 255, 255, 0.72);
  cursor: pointer;
  transition: background 120ms ease, color 120ms ease;
  white-space: nowrap; line-height: 1.4;
}
#foxes-plan-calculator-mount .fbg-tbtn.on{
  background: rgba(255, 255, 255, 0.18);
  color: var(--fx-white);
}
#foxes-plan-calculator-mount .fbg-tbtn:not(.on):hover{
  background: rgba(255, 255, 255, 0.1);
  color: var(--fx-white);
}

/* ── CTAs ──────────────────────────────────────────────────────────────── */
#foxes-plan-calculator-mount .fbg-actions{
  display: flex; flex-wrap: wrap; gap: 10px;
  margin-top: 20px;
}
#foxes-plan-calculator-mount .fbg-btn{
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 46px;
  padding: 0 24px;
  border-radius: var(--r-sm);
  text-decoration: none;
  font-family: 'Geist', sans-serif;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0;
  transition: background 200ms ease, color 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
  cursor: pointer;
}
/* Primary: solid red fill, white text */
#foxes-plan-calculator-mount .fbg-btn.p{
  background: var(--fx-red);
  color: var(--fx-white);
  box-shadow: 0 2px 8px rgba(12, 12, 12, 0.12);
}
#foxes-plan-calculator-mount .fbg-btn.p:hover{
  background: var(--fx-red-dark);
  box-shadow: 0 4px 12px rgba(12, 12, 12, 0.18);
}
/* Secondary / ghost: transparent fill, ink border, ink text */
#foxes-plan-calculator-mount .fbg-btn.g{
  background: transparent;
  color: var(--fx-ink);
  border: 2px solid var(--fx-ink);
}
#foxes-plan-calculator-mount .fbg-btn.g:hover{
  background: var(--fx-ink);
  color: var(--fx-white);
}

/* ── TERM BAR (card head variant with toggles) ─────────────────────────── */
#foxes-plan-calculator-mount .fbg-termbar{
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
  padding: 14px 24px;
  background: var(--fx-dark-grad);
  border-radius: var(--r) var(--r) 0 0;
}
#foxes-plan-calculator-mount .fbg-termbar-label{
  font-family: 'Geist', sans-serif;
  font-size: 13px; font-weight: 600;
  color: var(--fx-white) !important;
  display: inline-flex; align-items: center;
  letter-spacing: -0.005em;
}

/* ── FOCUS / SELECTION ─────────────────────────────────────────────────── */
#foxes-plan-calculator-mount ::selection{
  background: var(--fx-red-soft);
  color: var(--fx-ink);
}
#foxes-plan-calculator-mount *:focus-visible{
  outline: 2px solid var(--fx-red);
  outline-offset: 2px;
}

/* ── RESPONSIVE ────────────────────────────────────────────────────────── */
@media (max-width: 1100px){
  #foxes-plan-calculator-mount .fbg-fields{ grid-template-columns: 1fr 1fr; }
}
@media (max-width: 767px){
  #foxes-plan-calculator-mount .fbg-panel-head{ padding: 22px 20px 18px; }
  #foxes-plan-calculator-mount .fbg-panel-head h1{ font-size: 22px; }
  #foxes-plan-calculator-mount .fbg-panel-icon{
    width: 42px !important; height: 42px !important;
    border-radius: 11px !important;
  }
  #foxes-plan-calculator-mount .fbg-panel-body{ padding: 16px 18px 20px; }
  #foxes-plan-calculator-mount .fbg-panel-footer{ padding: 12px 18px; }
  #foxes-plan-calculator-mount .fbg-fields,
  #foxes-plan-calculator-mount .fbg-stats,
  #foxes-plan-calculator-mount .fbg-2{ grid-template-columns: 1fr; }
  #foxes-plan-calculator-mount .fbg-select,
  #foxes-plan-calculator-mount .fbg-input{ height: 46px; font-size: 15px; }
  #foxes-plan-calculator-mount .fbg-hero{ padding: 22px 20px 20px; }
  #foxes-plan-calculator-mount .fbg-hero h2{ font-size: 20px; }
  #foxes-plan-calculator-mount .fbg-stats{
    grid-template-columns: repeat(2, 1fr);
    gap: 8px; margin-top: 16px;
  }
  #foxes-plan-calculator-mount .fbg-stat-v{ font-size: 16px; }
  #foxes-plan-calculator-mount .fbg-card-hd,
  #foxes-plan-calculator-mount .fbg-card-bd{ padding-left: 18px; padding-right: 18px; }
  #foxes-plan-calculator-mount .fbg-termbar{
    padding-left: 18px; padding-right: 18px;
    flex-wrap: wrap; gap: 10px;
  }
  #foxes-plan-calculator-mount .fbg-btn{
    min-height: 50px; width: 100%; justify-content: center;
  }
  #foxes-plan-calculator-mount .fbg-row-v{ white-space: normal; }
  #foxes-plan-calculator-mount .fbg-bigrow-v{ font-size: 16px; }
  #foxes-plan-calculator-mount .fbg-narrative,
  #foxes-plan-calculator-mount .fbg-body{ font-size: 14px; line-height: 1.6; }
}

/* ── SCENARIO CARDS (estimator-style mortgage results) ─────────────────── */
#foxes-plan-calculator-mount .fbg-compliance-note{
  background: #FBF1DC;
  border: 1px solid #ECDCB6;
  border-radius: var(--r-sm);
  padding: 10px 14px;
  margin: 0 0 16px;
}
#foxes-plan-calculator-mount .fbg-compliance-note p{
  margin: 0;
  font-size: 12px;
  line-height: 1.5;
  color: #6B5A33;
}
#foxes-plan-calculator-mount .fbg-scen-card{
  background: var(--fx-white);
  border: 1px solid var(--fx-rule);
  border-radius: var(--r-sm);
  padding: 16px 18px;
}
#foxes-plan-calculator-mount .fbg-scen-top{
  display: flex; flex-direction: column;
}
#foxes-plan-calculator-mount .fbg-scen-pill{
  align-self: flex-start;
  display: inline-block;
  font-size: 10px; font-weight: 600;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--fx-red-soft);
  color: var(--fx-red-dark);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
#foxes-plan-calculator-mount .fbg-scen-name{
  font-family: 'Geist', sans-serif;
  font-size: 16px; font-weight: 600;
  margin: 7px 0 0;
  line-height: 1.2;
  color: var(--fx-ink);
}
#foxes-plan-calculator-mount .fbg-scen-desc{
  font-size: 12px; line-height: 1.5;
  margin: 9px 0 0;
  color: var(--ink-3);
}
#foxes-plan-calculator-mount .fbg-scen-calc{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 14px;
  background: var(--fx-cream);
  border: 1px solid var(--fx-rule);
  border-radius: var(--r-sm);
  padding: 12px 14px;
  margin: 11px 0 9px;
}
#foxes-plan-calculator-mount .fbg-scen-lbl{
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-3);
  margin: 0 0 4px;
  font-weight: 600;
}
#foxes-plan-calculator-mount .fbg-rate-control{ position: relative; max-width: 120px; }
#foxes-plan-calculator-mount .fbg-rate-in{
  width: 100%;
  box-sizing: border-box;
  font-family: 'Geist', sans-serif;
  font-size: 14px; font-weight: 600;
  background: var(--fx-white);
  border: 1px solid #D8C9A8;
  border-radius: var(--r-xs);
  padding: 7px 22px 7px 10px;
  color: var(--fx-ink);
  height: 34px;
  -moz-appearance: textfield;
}
#foxes-plan-calculator-mount .fbg-rate-in:focus{
  outline: none;
  border-color: var(--fx-red);
  box-shadow: 0 0 0 3px var(--fx-red-soft);
}
#foxes-plan-calculator-mount .fbg-rate-in::-webkit-outer-spin-button,
#foxes-plan-calculator-mount .fbg-rate-in::-webkit-inner-spin-button{ -webkit-appearance: none; margin: 0; }
#foxes-plan-calculator-mount .fbg-rate-pct{
  position: absolute; right: 9px; top: 8px;
  font-size: 13px; font-weight: 600;
  opacity: 0.5; pointer-events: none;
}
#foxes-plan-calculator-mount .fbg-scen-hero{
  font-family: 'Geist', sans-serif;
  font-size: 22px; font-weight: 600;
  margin: 0; line-height: 1.1;
  color: var(--fx-red);
  letter-spacing: -0.01em;
}
#foxes-plan-calculator-mount .fbg-scen-val{
  font-family: 'Geist', sans-serif;
  font-size: 16px; font-weight: 600;
  margin: 0; line-height: 1.15;
  color: var(--fx-ink);
}
#foxes-plan-calculator-mount .fbg-scen-extra{
  display: flex; flex-wrap: wrap;
  gap: 4px 16px;
  font-size: 11px;
  color: var(--ink-3);
  padding-top: 2px;
}
#foxes-plan-calculator-mount .fbg-scen-note{
  font-size: 10.5px; line-height: 1.45;
  margin: 9px 0 0;
  color: var(--ink-3);
}

/* ── LEGAL / IMPORTANT INFORMATION ─────────────────────────────────────── */
#foxes-plan-calculator-mount .fbg-legal{
  background: var(--fx-white);
  border: 1px solid var(--fx-rule);
  border-radius: var(--r-sm);
  padding: 16px 20px;
}
#foxes-plan-calculator-mount .fbg-legal h4{
  font-family: 'Geist', sans-serif;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 0 0 8px;
  color: var(--fx-ink);
  opacity: 0.7;
}
#foxes-plan-calculator-mount .fbg-legal p{
  font-size: 11px;
  line-height: 1.55;
  margin: 0 0 7px;
  color: var(--ink-3);
}
#foxes-plan-calculator-mount .fbg-legal p:last-child{ margin-bottom: 0; }
#foxes-plan-calculator-mount .fbg-legal strong{
  font-weight: 600;
  color: var(--fx-ink);
}
