/* ============================================
   Independent Financial Matters — Stylesheet v2
   Conservative-modern: Mercury / Wealthfront feel
   Navy, sage green, warm whites, gold accents
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Lora:wght@400;500;600;700&family=Source+Sans+3:wght@400;500;600;700&display=swap');

:root {
  --bg: #FAFAF8;
  --bg-soft: #F2F1ED;
  --bg-warm: #F7F5F0;
  --bg-navy: #1B2A4A;
  --bg-navy-deep: #0F1D36;
  --primary: #1B2A4A;
  --primary-light: rgba(27,42,74,0.06);
  --accent: #4A7C59;
  --accent-light: rgba(74,124,89,0.08);
  --accent-vivid: #5A9468;
  --gold: #B8860B;
  --gold-light: rgba(184,134,11,0.08);
  --text: #1E2637;
  --text-body: #4A5568;
  --text-muted: #8896A7;
  --text-on-dark: #C7CED8;
  --border: #DDD9D0;
  --border-light: #EAE7E0;
  --white: #FFFFFF;
  --font-heading: 'Lora', Georgia, serif;
  --font-body: 'Source Sans 3', -apple-system, BlinkMacSystemFont, sans-serif;
  --radius: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --shadow-xs: 0 1px 2px rgba(0,0,0,0.04);
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 20px rgba(0,0,0,0.07);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.08);
  --transition: 0.2s ease;
  --max-width: 1140px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text-body);
  line-height: 1.75;
  font-size: 16px;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--primary); }

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--text);
  line-height: 1.3;
  margin-bottom: 0.5em;
  font-weight: 600;
}
h1 { font-size: clamp(2rem, 4.5vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: clamp(1.15rem, 2vw, 1.4rem); }
h4 { font-size: 1.05rem; }
p { margin-bottom: 1rem; }

.container { width: 100%; max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }
.container--narrow { max-width: 760px; }

.section { padding: 80px 0; }
.section--soft { background: var(--bg-soft); }
.section--warm { background: var(--bg-warm); }
.section--navy { background: var(--bg-navy); color: var(--text-on-dark); }
.section--navy h2, .section--navy h3, .section--navy h4 { color: var(--white); }
.section--navy p { color: var(--text-on-dark); }

.grid { display: grid; gap: 28px; }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

.text-center { text-align: center; }

.eyebrow {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}
.subheading { font-size: 1.1rem; color: var(--text-muted); max-width: 560px; line-height: 1.8; }

/* ---- Nav ---- */
.nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(250,250,248,0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-light);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.nav__logo { display: flex; align-items: center; text-decoration: none; }
.nav__logo-text { font-family: var(--font-heading); font-size: 1.15rem; font-weight: 700; color: var(--primary); }
.nav__links { display: flex; align-items: center; gap: 28px; list-style: none; }
.nav__link { font-size: 0.9rem; font-weight: 500; color: var(--text-body); text-decoration: none; transition: color var(--transition); }
.nav__link:hover { color: var(--text); }
.nav__link--active { color: var(--accent); }
.nav__cta { margin-left: 8px; }
.nav__toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; color: var(--text); }
.nav__toggle svg { width: 24px; height: 24px; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 24px; font-family: var(--font-body); font-size: 0.9rem; font-weight: 600;
  border-radius: var(--radius); border: 2px solid transparent;
  cursor: pointer; transition: all var(--transition); text-decoration: none; line-height: 1.4;
}
.btn--primary { background: var(--accent); color: var(--white); border-color: var(--accent); }
.btn--primary:hover { background: #3D6A4B; border-color: #3D6A4B; color: var(--white); }
.btn--outline { background: transparent; color: var(--text); border-color: var(--border); }
.btn--outline:hover { border-color: var(--accent); color: var(--accent); }
.btn--ghost { background: transparent; color: var(--white); border: 2px solid rgba(255,255,255,0.25); }
.btn--ghost:hover { border-color: rgba(255,255,255,0.5); color: var(--white); }
.btn--navy { background: var(--primary); color: var(--white); border-color: var(--primary); }
.btn--navy:hover { background: var(--bg-navy-deep); }
.btn--large { padding: 14px 32px; font-size: 0.95rem; border-radius: var(--radius-lg); }
.btn-group { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---- Hero (compact gradient) ---- */
.hero {
  position: relative;
  padding: 80px 0 88px;
  background: linear-gradient(160deg, var(--bg-navy) 0%, #243a5e 60%, var(--accent) 100%);
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -30%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(74,124,89,0.12) 0%, transparent 70%);
  pointer-events: none;
}
.hero--home { padding: 96px 0 108px; }
.hero h1 { color: var(--white); margin-bottom: 16px; max-width: 560px; }
.hero .subheading { color: rgba(255,255,255,0.7); margin-bottom: 32px; max-width: 500px; }

/* Hero overlap card (stats bar) */
.hero-overlap {
  position: relative;
  margin-top: -56px;
  z-index: 10;
}
.hero-overlap__inner {
  background: var(--white);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: 40px 48px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  text-align: center;
}
.hero-overlap__number {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1.2;
}
.hero-overlap__label { font-size: 0.85rem; color: var(--text-muted); margin-top: 4px; }

/* ---- Cards (base) ---- */
.card {
  background: var(--white); border: 1px solid var(--border-light); border-radius: var(--radius-lg);
  padding: 32px; transition: box-shadow var(--transition), transform var(--transition);
  position: relative; overflow: hidden;
}
.card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.card--accent-top::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, var(--accent), var(--primary)); }
.card__icon { width: 44px; height: 44px; border-radius: var(--radius); display: flex; align-items: center; justify-content: center; margin-bottom: 14px; }
.card__icon svg { width: 22px; height: 22px; }
.card__icon--green { background: var(--accent-light); color: var(--accent); }
.card__icon--navy { background: var(--primary-light); color: var(--primary); }
.card__icon--gold { background: var(--gold-light); color: var(--gold); }
.card__title { font-size: 1.05rem; margin-bottom: 6px; }
.card__text { font-size: 0.9rem; color: var(--text-muted); margin-bottom: 0; }

/* ---- Hover-Reveal Cards ---- */
.hover-card {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  position: relative;
  overflow: hidden;
  transition: box-shadow 0.3s ease, transform 0.3s ease;
  cursor: default;
}
.hover-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--primary));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}
.hover-card:hover::before { transform: scaleX(1); }
.hover-card:hover { box-shadow: var(--shadow-md); transform: translateY(-4px); }

.hover-card__icon {
  width: 48px; height: 48px; border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px;
  transition: transform 0.3s ease;
}
.hover-card__icon svg { width: 24px; height: 24px; }
.hover-card:hover .hover-card__icon { transform: scale(1.1); }

.hover-card__title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
  transition: color 0.3s ease;
}
.hover-card:hover .hover-card__title { color: var(--accent); }

.hover-card__body {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.4s ease, opacity 0.3s ease 0.05s;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.7;
}
.hover-card:hover .hover-card__body {
  max-height: 220px;
  opacity: 1;
}
.hover-card__cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  margin-top: 12px;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.3s ease 0.1s, transform 0.3s ease 0.1s;
}
.hover-card__cta svg { width: 14px; height: 14px; }
.hover-card:hover .hover-card__cta { opacity: 1; transform: translateY(0); }

/* ---- Split-Screen / Sticky-Scroll Section ---- */
.sticky-reveal { padding: 0; }
.sticky-reveal .container { max-width: var(--max-width); }

.sticky-scroll {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.sticky-left {
  position: sticky;
  top: 100px;
  padding: 80px 0;
}
.sticky-left .eyebrow { margin-bottom: 12px; }
.sticky-left h2 { margin-bottom: 16px; }
.sticky-left p { color: var(--text-muted); max-width: 420px; }
.sticky-left .btn { margin-top: 24px; }

.scroll-right {
  padding: 80px 0;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.scroll-feature {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 32px;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.scroll-feature.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.scroll-feature:hover { box-shadow: var(--shadow-md); }

.scroll-feature__number {
  font-family: var(--font-heading);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}
.scroll-feature__title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}
.scroll-feature__text {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.75;
  margin-bottom: 0;
}
.scroll-feature__image {
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 16px;
}
.scroll-feature__image img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}
.scroll-feature__checks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-top: 14px;
}
.scroll-feature__check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text);
}
.scroll-feature__check svg { width: 15px; height: 15px; min-width: 15px; }

/* ---- Timeline / Vertical Process ---- */
.timeline {
  position: relative;
  padding: 0;
  max-width: 680px;
  margin: 0 auto;
}
.timeline::before {
  content: '';
  position: absolute;
  top: 0;
  left: 31px;
  width: 2px;
  height: 100%;
  background: linear-gradient(to bottom, var(--accent), var(--primary));
  border-radius: 2px;
}

.timeline-item {
  position: relative;
  padding-left: 80px;
  padding-bottom: 48px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.timeline-item.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.timeline-item:last-child { padding-bottom: 0; }

.timeline-marker {
  position: absolute;
  left: 16px;
  top: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  box-shadow: 0 0 0 4px var(--bg), 0 0 0 6px var(--accent-light);
  z-index: 1;
}
.section--soft .timeline-marker { box-shadow: 0 0 0 4px var(--bg-soft), 0 0 0 6px var(--accent-light); }

.timeline-item__title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}
.timeline-item__text {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.75;
  margin-bottom: 0;
}

/* ---- Testimonial Horizontal Scroll ---- */
.testimonial-track {
  display: flex;
  gap: 24px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 16px;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.testimonial-track::-webkit-scrollbar { height: 6px; }
.testimonial-track::-webkit-scrollbar-track { background: transparent; }
.testimonial-track::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

.testimonial {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 32px;
  scroll-snap-align: start;
  flex: 0 0 360px;
  min-width: 320px;
}
.testimonial__quote {
  font-size: 0.95rem;
  font-style: italic;
  color: var(--text-body);
  margin-bottom: 20px;
  line-height: 1.8;
  position: relative;
  padding-top: 8px;
}
.testimonial__quote::before {
  content: '\201C';
  font-family: Georgia, serif;
  font-size: 3rem;
  color: var(--accent);
  line-height: 0;
  position: absolute;
  top: 24px;
  left: 0;
  opacity: 0.3;
}
.testimonial__author { font-weight: 600; color: var(--text); font-size: 0.9rem; }
.testimonial__role { font-size: 0.82rem; color: var(--text-muted); }

/* ---- Feature Strip ---- */
.feature-strip { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.feature-strip--reverse .feature-strip__image { order: 2; }
.feature-strip--reverse .feature-strip__text { order: 1; }
.feature-strip__image { border-radius: var(--radius-xl); overflow: hidden; box-shadow: var(--shadow-lg); }
.feature-strip__image img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---- Article ---- */
.article { max-width: 740px; margin: 0 auto; }
.article h2 { margin-top: 36px; margin-bottom: 14px; }
.article p { font-size: 1.02rem; line-height: 1.85; }

/* ---- Blockquote ---- */
.blockquote {
  border-left: 4px solid var(--accent);
  padding: 28px 0 28px 36px;
  margin: 0;
}
.blockquote__text {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-style: italic;
  color: var(--text);
  line-height: 1.7;
  margin-bottom: 16px;
}
.blockquote__author { font-size: 0.9rem; font-weight: 600; color: var(--text); }
.blockquote__role { font-size: 0.85rem; color: var(--text-muted); }

/* ---- CTA Banner ---- */
.cta-banner {
  background: var(--bg-navy);
  padding: 64px 0;
}
.cta-banner__inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 48px;
  align-items: center;
}
.cta-banner h2 { color: var(--white); margin-bottom: 8px; }
.cta-banner p { color: var(--text-on-dark); margin-bottom: 0; }

/* ---- Contact Form ---- */
.contact-grid {
  display: grid;
  grid-template-columns: 7fr 5fr;
  gap: 56px;
  align-items: start;
}
.form-group { margin-bottom: 0; }
.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}
.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 12px 16px;
  font-family: var(--font-body);
  font-size: 0.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--text);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(74,124,89,0.1);
}
.form-textarea { resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* ---- Mega Footer ---- */
.mega-footer {
  background: var(--bg-navy-deep);
  color: var(--text-on-dark);
  padding: 64px 0 0;
}
.mega-footer__top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.mega-footer__brand-text {
  font-size: 0.88rem;
  color: var(--text-on-dark);
  opacity: 0.6;
  max-width: 300px;
  line-height: 1.7;
  margin-top: 14px;
}
.mega-footer__heading {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--white);
  margin-bottom: 16px;
}
.mega-footer__links { list-style: none; }
.mega-footer__links li { margin-bottom: 8px; }
.mega-footer__links a { color: var(--text-on-dark); opacity: 0.6; font-size: 0.88rem; text-decoration: none; transition: opacity var(--transition), color var(--transition); }
.mega-footer__links a:hover { opacity: 1; color: var(--accent-vivid); }

/* Newsletter form in footer */
.mega-footer__newsletter { margin-top: 4px; }
.mega-footer__newsletter p {
  font-size: 0.85rem;
  opacity: 0.6;
  margin-bottom: 12px;
  line-height: 1.6;
}
.newsletter-form {
  display: flex;
  gap: 8px;
}
.newsletter-form input {
  flex: 1;
  padding: 10px 14px;
  font-family: var(--font-body);
  font-size: 0.85rem;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--radius);
  background: rgba(255,255,255,0.06);
  color: var(--white);
  outline: none;
  transition: border-color 0.2s ease;
}
.newsletter-form input::placeholder { color: rgba(255,255,255,0.35); }
.newsletter-form input:focus { border-color: var(--accent-vivid); }
.newsletter-form button {
  padding: 10px 18px;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius);
  background: var(--accent);
  color: var(--white);
  cursor: pointer;
  transition: background 0.2s ease;
  white-space: nowrap;
}
.newsletter-form button:hover { background: #3D6A4B; }

/* Social links */
.mega-footer__social {
  display: flex;
  gap: 12px;
  margin-top: 16px;
}
.mega-footer__social a {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s ease;
}
.mega-footer__social a:hover { background: rgba(255,255,255,0.12); }
.mega-footer__social svg { width: 16px; height: 16px; color: rgba(255,255,255,0.6); }

/* Regulatory disclosure */
.mega-footer__disclosure {
  padding: 24px 0;
  border-top: 1px solid rgba(255,255,255,0.08);
  margin-top: 32px;
}
.mega-footer__disclosure-text {
  font-size: 0.75rem;
  color: var(--text-on-dark);
  opacity: 0.35;
  line-height: 1.7;
  max-width: 860px;
}

/* Footer bottom bar */
.mega-footer__bottom {
  border-top: 1px solid rgba(255,255,255,0.06);
  padding: 20px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--text-on-dark);
  opacity: 0.4;
}

/* ---- Fade-in animation utility ---- */
.fade-up {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.fade-up.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---- Responsive ---- */
@media (max-width: 1024px) {
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .sticky-scroll { grid-template-columns: 1fr; gap: 0; }
  .sticky-left { position: static; padding: 60px 0 0; }
  .scroll-right { padding: 32px 0 60px; }
  .mega-footer__top { grid-template-columns: 1fr 1fr; }
  .cta-banner__inner { grid-template-columns: 1fr; text-align: center; }
}
@media (max-width: 768px) {
  .section { padding: 56px 0; }
  .nav__links { display: none; }
  .nav__toggle { display: block; }
  .nav.is-open .nav__links {
    display: flex; flex-direction: column;
    position: absolute; top: 68px; left: 0; right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border-light);
    padding: 20px 24px; gap: 14px;
    box-shadow: var(--shadow-md);
  }
  .hero { padding: 64px 0 72px; }
  .hero--home { padding: 72px 0 84px; }
  .hero-overlap__inner { grid-template-columns: repeat(2, 1fr); padding: 28px; gap: 24px; }
  .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; }
  .feature-strip { grid-template-columns: 1fr; gap: 28px; }
  .feature-strip--reverse .feature-strip__image,
  .feature-strip--reverse .feature-strip__text { order: unset; }
  .contact-grid { grid-template-columns: 1fr; }
  .mega-footer__top { grid-template-columns: 1fr; gap: 32px; }
  .mega-footer__bottom { flex-direction: column; gap: 8px; text-align: center; }
  .testimonial { flex: 0 0 300px; min-width: 280px; }
}
@media (max-width: 480px) {
  .btn-group { flex-direction: column; }
  .btn-group .btn { width: 100%; justify-content: center; }
  .hero-overlap__inner { grid-template-columns: 1fr; }
  .newsletter-form { flex-direction: column; }
  .form-row { grid-template-columns: 1fr; }
}
