/* ==========================================================================
   Monterey Wealth — site styles
   ========================================================================== */
:root {
  --navy: #1f3d5c;
  --navy-dk: #152c45;
  --navy-xdk: #0c1c2e;
  --blue: #2a6496;
  --slate: #9a9ea3;
  --ice: #eef2f6;
  --text: #24292f;
  --muted: #5a6470;
  --line: #d9dee4;
  --line-lt: #e9ecf0;
  --bg-alt: #f5f7f9;
  --white: #fff;

  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", "Helvetica Neue", Arial, sans-serif;
  --max: 1240px;
  --gutter: clamp(20px, 4vw, 40px);
  --header-h: 92px;
  --shadow: 0 1px 2px rgba(12,28,46,.06), 0 8px 24px rgba(12,28,46,.08);
  --shadow-lg: 0 2px 4px rgba(12,28,46,.06), 0 18px 48px rgba(12,28,46,.14);
}

/* ---------- Base ---------- */
*,*::before,*::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 20px); }
body { margin: 0; font-family: var(--sans); font-size: 17.5px; line-height: 1.65; color: var(--text); background: #fff; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: var(--blue); text-underline-offset: 2px; }
a:hover { color: var(--navy-dk); }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.skip { position: absolute; left: -9999px; top: 6px; background: var(--navy); color: #fff; padding: 8px 14px; z-index: 100; }
.skip:focus { left: 12px; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

h1,h2,h3,h4 { font-family: var(--serif); color: var(--navy-dk); font-weight: 600; line-height: 1.2; margin: 0 0 .55em; letter-spacing: -.005em; }
h1 { font-size: clamp(2.1rem, 4vw, 3rem); }
h2 { font-size: clamp(1.7rem, 2.8vw, 2.35rem); }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.05rem; }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1.2em; padding-left: 1.25em; }
li { margin-bottom: .4em; }
.muted { color: var(--muted); }
.small { font-size: .9rem; }
.kicker { display: block; font-size: .78rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--blue); margin-bottom: 12px; }
.rule-title { position: relative; padding-bottom: 16px; margin-bottom: 24px; }
.rule-title::after { content: ""; position: absolute; left: 0; bottom: 0; width: 48px; height: 3px; background: var(--navy); }
.rule-title.center::after { left: 50%; transform: translateX(-50%); }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 12px 26px; background: var(--navy); color: #fff; border: 1px solid var(--navy); border-radius: 2px; font: 600 .98rem/1.2 var(--sans); letter-spacing: .01em; text-decoration: none; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.btn:hover { background: var(--navy-xdk); border-color: var(--navy-xdk); color: #fff; }
.btn-outline { background: transparent; color: var(--navy); }
.btn-outline:hover { background: var(--navy); color: #fff; }
.btn-light { background: #fff; color: var(--navy-dk); border-color: #fff; }
.btn-light:hover { background: var(--ice); color: var(--navy-dk); border-color: var(--ice); }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.7); }
.btn-ghost:hover { background: #fff; color: var(--navy-dk); border-color: #fff; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
.more { font-weight: 700; text-decoration: none; color: var(--blue); }
.more::after { content: " \2192"; transition: margin .15s; }
.more:hover::after { margin-left: 4px; }
.more:hover { text-decoration: underline; }

/* ---------- Utility bar ---------- */
.utility { background: var(--navy-xdk); color: #b8c4d1; font-size: .84rem; }
.utility .wrap { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 38px; }
.utility a { color: #dfe6ee; text-decoration: none; }
.utility a:hover { color: #fff; text-decoration: underline; }
.utility .u-l, .utility .u-r { display: flex; gap: 20px; align-items: center; }
.utility .sep { opacity: .35; }
@media (max-width: 760px) { .utility .hide-sm { display: none; } .utility .u-l { gap: 12px; } }

/* ---------- Header ---------- */
.site-header { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; box-shadow: 0 2px 12px rgba(12,28,46,.05); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: var(--header-h); }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; flex: none; }
.logo svg { width: 60px; height: 40px; flex: none; }
.logo-text { display: flex; flex-direction: column; align-items: center; line-height: 1; }
.logo-text .lt-1 { font-family: var(--serif); font-size: 1.8rem; font-weight: 500; color: var(--navy); letter-spacing: .045em; }
.logo-text .lt-2 { display: flex; align-items: center; gap: 8px; width: 100%; margin-top: 4px; font-family: var(--serif); font-size: .7rem; letter-spacing: .34em; color: #7d838a; }
.logo-text .lt-2::before, .logo-text .lt-2::after { content: ""; flex: 1; height: 1px; background: #b5bac0; }

.nav { display: flex; align-items: center; height: 100%; }
.nav > ul { list-style: none; margin: 0; padding: 0; display: flex; height: 100%; }
.nav > ul > li { position: relative; margin: 0; display: flex; }
.nav > ul > li > a { display: flex; align-items: center; padding: 0 16px; font-size: 1rem; font-weight: 600; color: var(--navy-dk); text-decoration: none; position: relative; }
.nav > ul > li > a::after { content: ""; position: absolute; left: 16px; right: 16px; bottom: -1px; height: 3px; background: var(--navy); transform: scaleX(0); transition: transform .2s; }
.nav > ul > li:hover > a::after, .nav > ul > li:focus-within > a::after, .nav > ul > li.current > a::after { transform: scaleX(1); }
.nav .sub { list-style: none; margin: 0; padding: 10px 0; position: absolute; top: 100%; left: 0; min-width: 270px; background: #fff; border: 1px solid var(--line); border-top: 0; box-shadow: var(--shadow-lg); opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .15s, transform .15s, visibility .15s; }
.nav li:hover > .sub, .nav li:focus-within > .sub { opacity: 1; visibility: visible; transform: none; }
.nav .sub li { margin: 0; }
.nav .sub a { display: block; padding: 10px 22px; font-size: .97rem; color: var(--text); text-decoration: none; border-left: 3px solid transparent; }
.nav .sub a:hover { background: var(--bg-alt); color: var(--navy-dk); border-left-color: var(--navy); }
.nav .btn { margin-left: 18px; }
.menu-toggle { display: none; background: #fff; border: 1px solid var(--line); border-radius: 2px; padding: 10px 16px; font: 600 .95rem var(--sans); color: var(--navy-dk); cursor: pointer; }
@media (max-width: 1100px) {
  :root { --header-h: 76px; }
  .nav { display: none; }
  .menu-toggle { display: block; }
}
@media (max-width: 420px) { .logo-text .lt-1 { font-size: 1.4rem; } .logo svg { width: 46px; } }

.mobile-nav { display: none; border-top: 1px solid var(--line); background: #fff; max-height: calc(100vh - 110px); overflow-y: auto; }
.mobile-nav.open { display: block; }
.mobile-nav ul { list-style: none; margin: 0; padding: 0; }
.mobile-nav li { margin: 0; }
.mobile-nav a { display: block; padding: 13px var(--gutter); border-bottom: 1px solid var(--line-lt); color: var(--navy-dk); text-decoration: none; font-weight: 600; }
.mobile-nav .sub a { padding-left: calc(var(--gutter) + 16px); font-weight: 400; color: var(--text); background: var(--bg-alt); }
.mobile-nav .m-cta { padding: 16px var(--gutter) 22px; }
.mobile-nav .m-cta .btn { display: flex; width: 100%; }
@media (min-width: 1101px) { .mobile-nav { display: none !important; } }

/* ---------- Home hero ---------- */
.hero { position: relative; color: #fff; background: var(--navy-xdk) center/cover no-repeat; min-height: clamp(520px, 72vh, 680px); display: flex; align-items: center; }
.hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(12,28,46,.94) 0%, rgba(12,28,46,.82) 45%, rgba(12,28,46,.35) 100%); }
.hero .wrap { position: relative; width: 100%; padding-top: 72px; padding-bottom: 130px; }
.hero-inner { max-width: 700px; }
.hero .kicker { color: #a9c4de; }
.hero h1 { color: #fff; font-size: clamp(2.4rem, 5vw, 3.7rem); line-height: 1.1; margin-bottom: 22px; }
.hero .lead { font-size: clamp(1.08rem, 1.5vw, 1.25rem); color: #d6dfe8; margin-bottom: 34px; max-width: 60ch; }
@media (max-width: 700px) { .hero::before { background: rgba(12,28,46,.86); } .hero .wrap { padding-bottom: 110px; } }

/* Stat band overlapping the hero */
.facts { position: relative; z-index: 2; margin-top: -70px; }
.facts ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); background: #fff; box-shadow: var(--shadow-lg); border-top: 4px solid var(--navy); }
.facts li { margin: 0; padding: 28px 26px; border-left: 1px solid var(--line-lt); }
.facts li:first-child { border-left: 0; }
.facts strong { display: block; font-family: var(--serif); font-size: 1.35rem; font-weight: 600; color: var(--navy-dk); margin-bottom: 4px; }
.facts span { font-size: .93rem; color: var(--muted); }
@media (max-width: 860px) { .facts ul { grid-template-columns: 1fr 1fr; } .facts li:nth-child(3) { border-left: 0; } .facts li:nth-child(n+3) { border-top: 1px solid var(--line-lt); } }
@media (max-width: 460px) { .facts li { padding: 18px 16px; } .facts strong { font-size: 1.1rem; } .facts span { font-size: .84rem; line-height: 1.4; display: block; } }

/* ---------- Sections ---------- */
.section { padding: clamp(64px, 8vw, 104px) 0; }
.section.alt { background: var(--bg-alt); border-top: 1px solid var(--line-lt); border-bottom: 1px solid var(--line-lt); }
.section-head { max-width: 780px; margin-bottom: 44px; }
.section-head p { font-size: 1.1rem; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

.cols { display: grid; gap: 32px; }
.cols-2 { grid-template-columns: 1fr 1fr; }
.cols-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .cols-3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 680px) { .cols-2, .cols-3 { grid-template-columns: 1fr; } }

/* Service cards (home) */
.service-group { background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow); display: flex; flex-direction: column; }
.service-group .sg-img { width: 100%; height: 240px; object-fit: cover; }
.service-group .sg-body { padding: 30px 32px 32px; display: flex; flex-direction: column; flex: 1; }
.service-group h3 { font-size: 1.55rem; margin-bottom: 6px; }
.service-group .sg-intro { color: var(--muted); margin-bottom: 14px; }
.service-list { list-style: none; padding: 0; margin: 0 0 24px; border-top: 1px solid var(--line-lt); }
.service-list li { padding: 14px 0; border-bottom: 1px solid var(--line-lt); margin: 0; }
.service-list a { font-weight: 700; text-decoration: none; font-size: 1.03rem; color: var(--navy-dk); }
.service-list a:hover { color: var(--blue); text-decoration: underline; }
.service-list p { margin: 2px 0 0; font-size: .95rem; color: var(--muted); }
.service-group .more { margin-top: auto; }

/* Approach */
.principle { background: #fff; border: 1px solid var(--line); border-top: 4px solid var(--navy); padding: 32px 30px 26px; }
.principle .num { display: block; font-family: var(--serif); font-size: 2.6rem; line-height: 1; color: #c3ccd6; margin-bottom: 16px; }
.principle p { color: #3d4650; margin: 0; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; gap: 40px; } }

.checklist { list-style: none; padding: 0; }
.checklist li { position: relative; padding-left: 28px; margin-bottom: 10px; }
.checklist li::before { content: ""; position: absolute; left: 3px; top: .45em; width: 11px; height: 6px; border-left: 2px solid var(--blue); border-bottom: 2px solid var(--blue); transform: rotate(-45deg); }

/* ---------- Tables ---------- */
.table { width: 100%; border-collapse: collapse; margin: 0 0 1.5em; font-size: .97rem; background: #fff; }
.table th, .table td { text-align: left; padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table thead th { background: var(--navy); color: #fff; font-weight: 600; font-size: .9rem; letter-spacing: .02em; border-bottom: 0; }
.table tbody tr:nth-child(even) td { background: #f8fafb; }
.table tbody tr:hover td { background: var(--ice); }
.table td.nowrap { white-space: nowrap; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); margin-bottom: 1.5em; -webkit-overflow-scrolling: touch; }
@media (max-width: 640px) {
  .table-wrap .table { min-width: 580px; }
  .content > section > .table, .content > .table, .split .table { display: block; overflow-x: auto; }
}
.table-wrap .table { margin: 0; }
.table-wrap .table tbody tr:last-child td { border-bottom: 0; }

/* ---------- Team ---------- */
.team { display: grid; grid-template-columns: repeat(5, 1fr); gap: 24px; }
.team a { text-decoration: none; color: inherit; background: #fff; border: 1px solid var(--line); display: block; transition: box-shadow .2s, transform .2s; }
.team a:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.team img { width: 100%; aspect-ratio: 1; object-fit: cover; object-position: center 20%; }
.team strong { display: block; font-family: var(--serif); color: var(--navy-dk); font-size: 1.08rem; padding: 14px 16px 2px; }
.team span { display: block; font-size: .88rem; color: var(--muted); padding: 0 16px 16px; }
@media (max-width: 960px) { .team { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 560px) { .team { grid-template-columns: 1fr 1fr; gap: 14px; } }

.bio { display: grid; grid-template-columns: 230px 1fr; gap: 36px; padding: 40px 0; border-bottom: 1px solid var(--line); }
.bio:first-of-type { padding-top: 0; }
.bio img { width: 100%; aspect-ratio: 1; object-fit: cover; object-position: center 20%; box-shadow: var(--shadow); }
.content .bio h2, .bio h2 { font-size: 1.65rem; margin: 0 0 2px; padding-top: 0; border-top: 0; }
.bio .title { font-weight: 700; font-size: .85rem; letter-spacing: .1em; text-transform: uppercase; color: var(--blue); margin-bottom: 16px; }
.bio .direct { font-size: .97rem; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line-lt); }
@media (max-width: 640px) { .bio { grid-template-columns: 1fr; gap: 18px; } .bio img { max-width: 220px; } }

/* ---------- CTA band ---------- */
.cta { position: relative; color: #fff; background: var(--navy-dk) center/cover no-repeat; background-image: url("../img/meeting.jpg"); }
.cta::before { content: ""; position: absolute; inset: 0; background: rgba(12,28,46,.88); }
.cta .wrap { position: relative; display: flex; justify-content: space-between; align-items: center; gap: 32px; padding-top: 64px; padding-bottom: 64px; flex-wrap: wrap; }
.cta h2 { color: #fff; margin: 0 0 8px; }
.cta p { margin: 0; color: #cfd9e3; font-size: 1.1rem; }
.cta .phone { color: #fff; font-weight: 700; }
.cta .btn-row { flex: none; }

/* ---------- Inner page header ---------- */
.page-title { position: relative; color: #fff; background: var(--navy-dk) center/cover no-repeat; padding: 64px 0 58px; }
.page-title::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(12,28,46,.95) 0%, rgba(12,28,46,.85) 50%, rgba(12,28,46,.6) 100%); }
.page-title .wrap { position: relative; }
.page-title h1 { color: #fff; margin: 0; font-size: clamp(2.1rem, 4vw, 3rem); }
.page-title .pt-lede { margin: 12px 0 0; max-width: 62ch; font-size: 1.15rem; color: #d3dde7; }
.crumbs { font-size: .86rem; color: #a9b8c8; margin-bottom: 14px; }
.crumbs a { color: #dbe4ed; text-decoration: none; }
.crumbs a:hover { text-decoration: underline; color: #fff; }

.page-body { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 64px; padding-top: 60px; padding-bottom: 88px; align-items: start; }
.content h2 { margin-top: 1.7em; padding-top: 1.4em; border-top: 1px solid var(--line); }
.content > h2:first-child, .content > section:first-child > h2:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.content section + section > h2 { margin-top: 1.7em; padding-top: 1.4em; border-top: 1px solid var(--line); }
.content .lead { font-size: 1.15rem; color: #3d4650; }
.content h3 { margin-top: 1.5em; }
@media (max-width: 980px) { .page-body { grid-template-columns: 1fr; gap: 40px; padding-top: 44px; } }

.sidebar { position: sticky; top: calc(var(--header-h) + 24px); display: grid; gap: 24px; }
.side-box { border: 1px solid var(--line); background: #fff; box-shadow: var(--shadow); }
.side-box h4 { margin: 0; padding: 14px 22px; background: var(--navy); color: #fff; font-family: var(--sans); font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; }
.side-box ul { list-style: none; margin: 0; padding: 6px 0; }
.side-box li { margin: 0; }
.side-box li a { display: block; padding: 10px 22px; text-decoration: none; color: var(--text); font-size: .97rem; border-left: 3px solid transparent; }
.side-box li a:hover { background: var(--bg-alt); color: var(--navy-dk); border-left-color: var(--navy); }
.side-box .pad { padding: 20px 22px 22px; font-size: .96rem; }
.side-box .pad p { margin-bottom: 10px; }
.side-box .pad .btn { display: flex; width: 100%; }
.side-box .big-phone { font-family: var(--serif); font-size: 1.5rem; font-weight: 600; color: var(--navy-dk); text-decoration: none; }
@media (max-width: 980px) { .sidebar { position: static; } }

.note { background: var(--ice); border-left: 4px solid var(--navy); padding: 16px 20px; font-size: .96rem; margin: 0 0 1.5em; }

.doclist { list-style: none; padding: 0; margin: 0 0 1.5em; border: 1px solid var(--line); }
.doclist li { margin: 0; border-bottom: 1px solid var(--line-lt); }
.doclist li:last-child { border-bottom: 0; }
.doclist a { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 15px 20px; text-decoration: none; color: var(--navy-dk); }
.doclist a span { font-size: .75rem; font-weight: 700; letter-spacing: .08em; color: var(--muted); border: 1px solid var(--line); padding: 3px 8px; }
.doclist a:hover { background: var(--bg-alt); }
.doclist a:hover strong { text-decoration: underline; }

.portals { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.portal { background: #fff; border: 1px solid var(--line); border-top: 4px solid var(--navy); padding: 32px 30px; display: flex; flex-direction: column; box-shadow: var(--shadow); transition: box-shadow .2s, transform .2s; }
.portal:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.portal h3 { margin-bottom: 8px; font-size: 1.5rem; }
.portal p { color: var(--muted); font-size: .97rem; flex: 1; }
.portal .btn { align-self: flex-start; }
@media (max-width: 820px) { .portals { grid-template-columns: 1fr; } }

.contact-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; }
.contact-grid dl { margin: 0; border-top: 1px solid var(--line); }
.contact-grid dt { font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); padding-top: 18px; }
.contact-grid dd { margin: 4px 0 0; padding-bottom: 18px; border-bottom: 1px solid var(--line); font-size: 1.08rem; }
.map { border: 1px solid var(--line); box-shadow: var(--shadow); }
.map iframe { width: 100%; height: 100%; min-height: 420px; border: 0; display: block; }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; gap: 36px; } }

/* 404 */
.notfound { text-align: center; padding: 110px 0; }
.notfound .code { font-family: var(--serif); font-size: 5rem; line-height: 1; color: #c3ccd6; margin-bottom: 10px; }
.notfound .btn-row { justify-content: center; margin-top: 24px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-xdk); color: #aebbc9; font-size: .95rem; }
.site-footer a { color: #e1e7ee; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.f-cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; padding: 72px 0 48px; }
.site-footer h4 { color: #fff; font-family: var(--sans); font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 18px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 9px; }
.site-footer address { font-style: normal; line-height: 1.7; }
.f-logo { margin-bottom: 18px; }
.f-logo .lt-1 { color: #fff !important; }
.f-logo .lt-2 { color: #9fb0c2 !important; }
.f-logo .lt-2::before, .f-logo .lt-2::after { background: #4b6078 !important; }
.f-logo svg path[fill="#1f3d5c"] { fill: #e1e7ee; }
.f-legal { border-top: 1px solid rgba(255,255,255,.1); padding: 30px 0; font-size: .8rem; line-height: 1.7; color: #8798aa; }
.f-legal p { margin: 0 0 10px; max-width: 135ch; }
.f-bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 20px 0 28px; font-size: .84rem; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; color: #8798aa; }
@media (max-width: 900px) { .f-cols { grid-template-columns: 1fr 1fr; } }
@media (max-width: 540px) { .f-cols { grid-template-columns: 1fr; padding-top: 52px; } }

@media print {
  .utility, .site-header, .sidebar, .cta, .site-footer .f-cols { display: none !important; }
  .page-title, .hero { background: none !important; color: #000; }
  .page-title::before, .hero::before { display: none; }
  .page-title h1, .hero h1 { color: #000; }
}
