/* ============================================================
   JonatanMars Invest — Website stylesheet
   Built on tokens.css (brand foundation). Dark-led, gold-precious,
   beige-softened, type-as-hero, sharp corners, hairline rules.
   Mobile-first; scales up to a 1200px institutional grid.
   ============================================================ */

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: var(--font-text);
  font-variation-settings: var(--fv-regular);
  background: var(--bg-invert);
  color: var(--text-invert);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  line-height: 1.6;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
ul { list-style: none; }
::selection { background: var(--jm-gold-500); color: var(--jm-blue-900); }

/* ---------- Responsive type overrides (clamp the fixed scale) ---------- */
.jm-display { font-size: clamp(2.85rem, 9.5vw, 95px); line-height: 1.02; letter-spacing: -0.01em; }
.jm-h1 { font-size: clamp(2.35rem, 7.2vw, 76px); line-height: 1.08; letter-spacing: -0.01em; }
.jm-h2 { font-size: clamp(2rem, 5.6vw, 61px); line-height: 1.1; letter-spacing: -0.005em; }
.jm-h3 { font-size: clamp(1.6rem, 4.2vw, 49px); line-height: 1.14; }
.jm-h4 { font-size: clamp(1.4rem, 3.2vw, 39px); line-height: 1.18; }
.jm-h5 { font-size: clamp(1.25rem, 2.4vw, 31px); line-height: 1.2; }
.jm-h5-medium { font-size: clamp(1.25rem, 2.4vw, 31px); line-height: 1.2; }
.jm-h6 { font-size: clamp(1.1rem, 1.7vw, 25px); line-height: 1.32; }
.jm-lead { font-size: clamp(1.05rem, 1.5vw, 20px); }
.jm-lead-bold { font-size: clamp(1.05rem, 1.5vw, 20px); }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: 1240px; margin-inline: auto; padding-inline: 20px; }
@media (min-width: 700px) { .container { padding-inline: 40px; } }
@media (min-width: 1100px) { .container { padding-inline: 56px; } }

.section { padding-block: clamp(56px, 9vw, 128px); position: relative; }
.section--tight { padding-block: clamp(40px, 6vw, 88px); }

/* Surface variants */
.surf-ink     { background: var(--bg-invert); color: var(--text-invert); }
.surf-deep    { background: var(--bg-invert-deep); color: var(--text-invert); }
.surf-raised  { background: var(--bg-invert-raised); color: var(--text-invert); }
.surf-paper   { background: var(--bg-paper); color: var(--text-body); }
.surf-light   { background: var(--bg-light); color: var(--text-body); }
.surf-white   { background: var(--bg-default); color: var(--text-body); }

/* On light surfaces, set heading/text colors to ink */
.surf-paper :is(h1,h2,h3,h4,h5,h6),
.surf-light :is(h1,h2,h3,h4,h5,h6),
.surf-white :is(h1,h2,h3,h4,h5,h6) { color: var(--text-title); }
.surf-paper .lead-muted, .surf-light .lead-muted, .surf-white .lead-muted { color: var(--text-body); }

/* On dark surfaces */
.surf-ink :is(h1,h2,h3,h4,h5,h6),
.surf-deep :is(h1,h2,h3,h4,h5,h6),
.surf-raised :is(h1,h2,h3,h4,h5,h6) { color: var(--text-invert-focused); }

/* ---------- Eyebrow / label + section number ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-variation-settings: var(--fv-medium);
  font-size: 13px; line-height: 1; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--text-brand);
}
.eyebrow::before {
  content: ""; width: 28px; height: 1px; background: var(--jm-gold-500); display: inline-block;
}
.eyebrow--plain::before { display: none; }
.eyebrow--muted { color: var(--text-invert-muted); }
.surf-paper .eyebrow--muted, .surf-light .eyebrow--muted, .surf-white .eyebrow--muted { color: var(--text-body-muted); }

.sec-num {
  font-variation-settings: var(--fv-medium);
  font-size: 13px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--text-brand);
}

/* ---------- Hairline rules ---------- */
.rule { height: 1px; background: var(--border-invert-hairline); border: 0; width: 100%; }
.surf-paper .rule, .surf-light .rule, .surf-white .rule { background: var(--border-hairline); }
.rule--gold { background: var(--jm-gold-500); opacity: .9; }

/* ---------- Buttons (label + divided arrow cell) ---------- */
.btn {
  display: inline-flex; align-items: stretch; border: 1px solid transparent;
  font-variation-settings: var(--fv-medium); font-size: 13px;
  letter-spacing: 0.07em; text-transform: uppercase;
  transition: background var(--dur-base) var(--ease-standard),
              color var(--dur-base) var(--ease-standard),
              border-color var(--dur-base) var(--ease-standard);
  white-space: nowrap;
}
.btn .lab { padding: 14px 18px; display: flex; align-items: center; }
.btn .arr { padding: 0 14px; display: flex; align-items: center; border-left: 1px solid currentColor; }
.btn .arr::after {
  content: ""; width: 18px; height: 18px; background: currentColor;
  -webkit-mask: var(--icon-arrow) center / contain no-repeat;
          mask: var(--icon-arrow) center / contain no-repeat;
  transition: transform var(--dur-base) var(--ease-standard);
}
.btn:hover .arr::after { transform: translateX(3px); }
/* normalise native <button class="btn"> to match <a class="btn"> */
button.btn { font-family: inherit; cursor: pointer; padding: 0; margin: 0; -webkit-appearance: none; appearance: none; }
/* On narrow screens let long button labels wrap instead of overflowing the viewport. */
@media (max-width: 520px) { .btn { white-space: normal; } .btn .lab { padding: 12px 16px; } }

:root {
  --icon-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.75'%3E%3Cline x1='4' y1='12' x2='19' y2='12'/%3E%3Cpolyline points='13 6 19 12 13 18'/%3E%3C/svg%3E");
  --icon-check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
}

.btn.dark { background: var(--jm-blue-900); color: #fff; border-color: var(--jm-blue-900); }
.btn.dark:hover { background: var(--jm-blue-850); border-color: var(--jm-blue-850); }
.btn.gold { background: var(--jm-gold-500); color: var(--jm-blue-900); border-color: var(--jm-gold-500); }
.btn.gold:hover { background: var(--jm-gold-400); border-color: var(--jm-gold-400); }
.btn.gold:active { background: var(--jm-gold-600); border-color: var(--jm-gold-600); }
.btn.outline { background: transparent; color: var(--jm-blue-900); border-color: var(--jm-blue-900); }
.btn.outline:hover { background: var(--jm-blue-900); color: #fff; }
.btn.outline-inv { background: transparent; color: #fff; border-color: rgba(255,255,255,.55); }
.btn.outline-inv:hover { background: #fff; color: var(--jm-blue-900); border-color: #fff; }
.btn.block { width: 100%; justify-content: space-between; }

/* text link with arrow */
.link-arrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-variation-settings: var(--fv-medium); font-size: 13px;
  letter-spacing: 0.07em; text-transform: uppercase; color: var(--text-brand);
  transition: gap var(--dur-base) var(--ease-standard);
}
.link-arrow::after {
  content: ""; width: 16px; height: 16px; background: currentColor;
  -webkit-mask: var(--icon-arrow) center / contain no-repeat;
          mask: var(--icon-arrow) center / contain no-repeat;
  transition: transform var(--dur-base) var(--ease-standard);
}
.link-arrow:hover::after { transform: translateX(3px); }
.link-arrow--muted { color: var(--text-invert); }
.surf-paper .link-arrow--muted, .surf-white .link-arrow--muted, .surf-light .link-arrow--muted { color: var(--text-body-focused); }

.btn-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(20,27,32,0.82);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--border-invert-hairline);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 24px; }
@media (min-width: 1000px) { .header-inner { height: 76px; } }

/* logo lockup */
.logo-lockup { display: inline-flex; align-items: center; gap: 13px; }
.logo-lockup .wm { height: 17px; width: auto; color: #fff; }
.logo-lockup .wm svg { height: 17px; width: auto; }
.logo-lockup .div { width: 1px; height: 22px; background: rgba(255,255,255,0.32); }
.logo-lockup .desc {
  font-variation-settings: var(--fv-medium); font-size: 14px;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--jm-gold-500);
  padding-right: 0.22em;
}
@media (max-width: 460px) {
  .logo-lockup { gap: 10px; }
  .logo-lockup .wm, .logo-lockup .wm svg { height: 15px; }
  .logo-lockup .div { height: 19px; }
  .logo-lockup .desc { font-size: 12px; letter-spacing: 0.18em; }
}

/* primary nav */
.nav { display: none; align-items: center; gap: 4px; }
@media (min-width: 1000px) { .nav { display: flex; } }
.nav a, .nav .navitem > button {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 14px; font-size: 14px; color: var(--text-invert);
  transition: color var(--dur-fast) var(--ease-standard);
}
.nav a:hover, .nav .navitem > button:hover { color: #fff; }
.nav a[aria-current], .nav .navitem > button[aria-current] { color: #fff; }
.navitem { position: relative; }
.dropdown {
  position: absolute; top: calc(100% + 8px); left: 0; min-width: 280px;
  background: var(--jm-blue-850); border: 1px solid var(--border-invert-hairline);
  box-shadow: var(--shadow-dark); padding: 8px;
  opacity: 0; visibility: hidden; transform: translateY(6px);
  transition: opacity var(--dur-base) var(--ease-standard), transform var(--dur-base) var(--ease-standard), visibility var(--dur-base);
}
.navitem:hover .dropdown, .navitem:focus-within .dropdown { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown a { display: block; padding: 12px 14px; }
.dropdown a strong { display: block; color: #fff; font-variation-settings: var(--fv-medium); font-size: 15px; }
.dropdown a span { display: block; font-size: 13px; color: var(--text-invert-muted); margin-top: 2px; }
.dropdown a:hover { background: rgba(255,255,255,0.04); }

.header-cta { display: none; align-items: center; gap: 16px; }
@media (min-width: 1000px) { .header-cta { display: flex; } }
.lang { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; letter-spacing: .06em; color: var(--text-invert-muted); }
.lang a, .lang .is-active { padding: 8px 4px; } /* larger tap target (2.5.5) */
.lang .is-active { color: #fff; }

/* mobile toggle */
.nav-toggle { display: inline-flex; flex-direction: column; gap: 5px; padding: 10px; }
@media (min-width: 1000px) { .nav-toggle { display: none; } }
.nav-toggle span { width: 24px; height: 1.5px; background: #fff; transition: transform var(--dur-base), opacity var(--dur-base); }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* mobile menu */
.mobile-menu {
  position: fixed; inset: 0 0 0 0; top: 68px; z-index: 99;
  background: var(--bg-invert-deep);
  transform: translateX(100%); transition: transform var(--dur-base) var(--ease-standard);
  overflow-y: auto; padding: 24px 20px 48px;
  display: flex; flex-direction: column; gap: 4px;
}
.mobile-menu.open { transform: translateX(0); }
@media (min-width: 1000px) { .mobile-menu { display: none; } }
.mobile-menu a { padding: 16px 4px; font-size: 20px; border-bottom: 1px solid var(--border-invert-hairline); display: flex; justify-content: space-between; align-items: center; color: #fff; }
.mobile-menu .sub a { font-size: 16px; color: var(--text-invert); padding-left: 16px; }
.mobile-menu .m-group-label { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--text-brand); padding: 20px 4px 6px; }
.mobile-menu .sub-direct { font-size: 17px; color: var(--text-invert); padding-left: 14px; }
.mobile-menu .sub-direct:first-of-type { border-top: 1px solid var(--border-invert-hairline); }
.mobile-menu .m-cta { margin-top: 24px; }
body.menu-open { overflow: hidden; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding-block: clamp(64px, 13vw, 168px); }
.hero .container { position: relative; z-index: 2; }
.hero-max { max-width: 940px; }
.hero .jm-lead { color: var(--text-invert); max-width: 660px; }
.tagline-italic { font-variation-settings: var(--fv-italic); color: var(--text-brand); font-size: clamp(1.05rem, 1.6vw, 20px); }

/* JM stencil hairline frame (homepage hero) */
.hero-frame {
  position: absolute; z-index: 1; pointer-events: none;
  top: clamp(20px, 4vw, 56px);
  right: clamp(16px, 3vw, 48px);
  bottom: clamp(20px, 4vw, 52px);
  left: clamp(16px, 3vw, 48px);
  color: var(--border-invert-muted);
}
.hero-frame svg { width: 100%; height: 100%; }
.hero-frame svg path { stroke: currentColor; stroke-width: 1.5; }
.hero-frame .hf-land { display: block; }
.hero-frame .hf-port { display: none; }
/* keep hero content inside the frame body (the stencil's left edge is inset
   from its foot, so nudge the copy in to clear the line) */
.hero--framed .hero-max { padding-left: clamp(34px, 6vw, 104px); padding-right: clamp(0px, 2vw, 28px); }
/* Desktop-only flourish — drop the frame and its indent on mobile */
@media (max-width: 760px) {
  .hero-frame { display: none; }
  .hero--framed .hero-max { padding-left: 0; padding-right: 0; }
}
.hero--framed .fineprint--hero { max-width: 600px; }

/* stencil background motif */
.stencil-bg {
  position: absolute; z-index: 1; color: var(--jm-blue-850); pointer-events: none;
  opacity: .5;
}
.stencil-bg.tr { top: -6%; right: -8%; width: min(58%, 620px); }
.stencil-bg.br { bottom: -14%; right: -6%; width: min(46%, 480px); opacity: .35; }
.stencil-bg.bl { bottom: -16%; left: -10%; width: min(50%, 520px); opacity: .3; }

/* ---------- Generic section heading block ---------- */
.section-head { max-width: 760px; }
.section-head .eyebrow { margin-bottom: 22px; }
.section-head .jm-h2, .section-head .jm-h3 { margin-bottom: 0; }
.section-head p { margin-top: 22px; }
.measure { max-width: 64ch; }
.measure-sm { max-width: 52ch; }

/* spacing helpers */
.mt-1{margin-top:8px}.mt-2{margin-top:16px}.mt-3{margin-top:24px}.mt-4{margin-top:32px}
.mt-5{margin-top:48px}.mt-6{margin-top:64px}
.mb-2{margin-bottom:16px}.mb-3{margin-bottom:24px}.mb-4{margin-bottom:32px}.mb-5{margin-bottom:48px}
.text-gold{color:var(--text-brand)}
.text-muted{color:var(--text-invert-muted)}
.surf-paper .text-muted,.surf-light .text-muted,.surf-white .text-muted{color:var(--text-body-muted)}

/* Gold as TEXT on light surfaces uses the darker gold for AA contrast (≥4.5:1).
   Gold fills, dividers, buttons, and the stencil are unaffected — this only retints gold text. */
.surf-paper .eyebrow:not(.eyebrow--muted), .surf-light .eyebrow:not(.eyebrow--muted), .surf-white .eyebrow:not(.eyebrow--muted),
.surf-paper .text-gold, .surf-light .text-gold, .surf-white .text-gold,
.surf-paper .eyebrow-gold, .surf-light .eyebrow-gold, .surf-white .eyebrow-gold,
.surf-paper .card .num, .surf-light .card .num, .surf-white .card .num,
.surf-paper .link-arrow:not(.link-arrow--muted), .surf-light .link-arrow:not(.link-arrow--muted), .surf-white .link-arrow:not(.link-arrow--muted) { color: var(--text-brand-on-light); }
.surf-paper .eyebrow:not(.eyebrow--muted)::before, .surf-light .eyebrow:not(.eyebrow--muted)::before, .surf-white .eyebrow:not(.eyebrow--muted)::before { background: var(--text-brand-on-light); }

/* ---------- Grids ---------- */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr; }
@media (min-width: 720px) { .grid-2 { grid-template-columns: 1fr 1fr; } .grid-4 { grid-template-columns: 1fr 1fr; } }
@media (min-width: 980px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } .grid-4 { grid-template-columns: repeat(4, 1fr); } }
.grid-split { display: grid; gap: clamp(32px, 5vw, 72px); grid-template-columns: 1fr; align-items: start; }
@media (min-width: 960px) { .grid-split { grid-template-columns: 0.85fr 1.15fr; } .grid-split.even { grid-template-columns: 1fr 1fr; } }

/* ---------- Cards ---------- */
.card {
  border: 1px solid var(--border-invert-hairline);
  background: var(--bg-invert-raised);
  padding: clamp(24px, 3vw, 36px);
  height: 100%;
  display: flex; flex-direction: column;
  transition: border-color var(--dur-base) var(--ease-standard), transform var(--dur-base) var(--ease-standard);
}
.card:hover { border-color: var(--border-invert-muted); }
.surf-paper .card, .surf-light .card, .surf-white .card {
  background: var(--bg-default); border: 1px solid var(--border-hairline); box-shadow: var(--shadow-sm); border-radius: var(--radius-md);
}
.surf-paper .card:hover, .surf-light .card:hover, .surf-white .card:hover { box-shadow: var(--shadow-md); border-color: var(--border-muted); }
.card .num { font-variation-settings: var(--fv-medium); font-size: 13px; letter-spacing: .14em; color: var(--text-brand); margin-bottom: 18px; }
.card h3, .card h4 { margin-bottom: 12px; }
.card p { color: var(--text-invert); }
.surf-paper .card p, .surf-white .card p, .surf-light .card p { color: var(--text-body); }
.card .card-foot { margin-top: auto; padding-top: 22px; }

/* engine card with gold rule accent */
.card--rule { border-top: 2px solid var(--jm-gold-500); }

/* product card */
.product-card { display: flex; flex-direction: column; gap: 14px; }
.product-card .meta { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 8px; }
.product-card .meta span { font-size: 13px; color: var(--text-invert-muted); }

/* ---------- Feature list / checks ---------- */
.feature-list { display: grid; gap: 4px; }
.feature-list li {
  display: grid; grid-template-columns: 22px 1fr; gap: 14px; align-items: start;
  padding: 18px 0; border-bottom: 1px solid var(--border-invert-hairline);
}
.surf-paper .feature-list li, .surf-light .feature-list li, .surf-white .feature-list li { border-color: var(--border-hairline); }
.feature-list li .ic {
  width: 22px; height: 22px; background: var(--jm-gold-500); margin-top: 2px;
  -webkit-mask: var(--icon-check) center / 20px no-repeat; mask: var(--icon-check) center / 20px no-repeat;
}
.feature-list li strong { display: block; color: #fff; font-variation-settings: var(--fv-medium); margin-bottom: 3px; }
.surf-paper .feature-list li strong, .surf-light .feature-list li strong, .surf-white .feature-list li strong { color: var(--text-title); }
.feature-list li span.t { color: var(--text-invert); }
.surf-paper .feature-list li span.t, .surf-white .feature-list li span.t, .surf-light .feature-list li span.t { color: var(--text-body); }

/* ---------- Numbered process steps ---------- */
.steps { display: grid; gap: 0; }
.step {
  display: grid; grid-template-columns: auto 1fr; gap: 22px; align-items: start;
  padding: 28px 0; border-top: 1px solid var(--border-invert-hairline);
}
.surf-paper .step, .surf-white .step, .surf-light .step { border-color: var(--border-hairline); }
.step:last-child { border-bottom: 1px solid var(--border-invert-hairline); }
.surf-paper .step:last-child, .surf-white .step:last-child, .surf-light .step:last-child { border-color: var(--border-hairline); }
.step .step-num {
  font-family: var(--font-display); font-variation-settings: var(--fv-display);
  font-size: clamp(2rem, 4vw, 44px); line-height: 1; color: var(--jm-gold-500); min-width: 1.6em;
}
.step h4 { margin-bottom: 8px; }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--border-invert-hairline); border: 1px solid var(--border-invert-hairline); }
@media (min-width: 760px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stat { background: var(--bg-invert); padding: 28px 22px; }
.stat .v { font-family: var(--font-display); font-variation-settings: var(--fv-display); font-size: clamp(2rem, 4vw, 46px); line-height: 1; color: #fff; }
.stat .v .text-gold { color: var(--jm-gold-500); }
.stat .k { margin-top: 10px; font-size: 14px; color: var(--text-invert-muted); }

/* ---------- Tables ---------- */
.table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.jm-table { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 520px; }
table.jm-table caption { text-align: left; }
table.jm-table th, table.jm-table td { padding: 16px 18px; text-align: left; border-bottom: 1px solid var(--border-invert-hairline); vertical-align: top; }
.surf-paper table.jm-table th, .surf-paper table.jm-table td,
.surf-white table.jm-table th, .surf-white table.jm-table td,
.surf-light table.jm-table th, .surf-light table.jm-table td { border-color: var(--border-hairline); }
table.jm-table thead th {
  font-variation-settings: var(--fv-medium); font-size: 12px; letter-spacing: .08em;
  text-transform: uppercase; color: var(--text-invert-muted); border-bottom: 1px solid var(--border-invert-muted);
}
.surf-paper table.jm-table thead th, .surf-white table.jm-table thead th, .surf-light table.jm-table thead th { color: var(--text-body-muted); border-color: var(--border-muted); }
table.jm-table tbody th { font-variation-settings: var(--fv-medium); color: #fff; }
.surf-paper table.jm-table tbody th, .surf-white table.jm-table tbody th, .surf-light table.jm-table tbody th { color: var(--text-title); }
table.jm-table .hl { color: var(--jm-gold-500); font-variation-settings: var(--fv-medium); }
table.jm-table .num-cell { text-align: center; font-variation-settings: var(--fv-medium); }
table.jm-table tbody tr:last-child td { border-bottom: 0; }

/* risk scale rows */
.risk-row td:first-child { color: var(--jm-gold-500); font-variation-settings: var(--fv-medium); }

/* ---------- Pull quote / calm note ---------- */
.pullquote {
  border-left: 2px solid var(--jm-gold-500); padding: 6px 0 6px 28px;
  font-family: var(--font-display); font-variation-settings: var(--fv-display);
  font-size: clamp(1.5rem, 3vw, 34px); line-height: 1.22; color: #fff; max-width: 22ch;
}
.surf-paper .pullquote, .surf-white .pullquote, .surf-light .pullquote { color: var(--text-title); }

.callout {
  border: 1px solid var(--border-invert-hairline); border-left: 2px solid var(--jm-gold-500);
  background: var(--bg-invert-raised); padding: clamp(22px, 3vw, 32px);
}
.surf-paper .callout, .surf-white .callout, .surf-light .callout { background: var(--jm-beige-100); border-color: var(--border-hairline); border-left-color: var(--jm-gold-600); }
.callout strong { color: #fff; }
.surf-paper .callout strong, .surf-white .callout strong, .surf-light .callout strong { color: var(--text-title); }

/* ---------- Tags / chips ---------- */
.chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px;
  border: 1px solid var(--border-invert-hairline); border-radius: var(--radius-pill);
  font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-invert);
}
.surf-paper .chip, .surf-white .chip, .surf-light .chip { border-color: var(--border-muted); color: var(--text-body); }
.chip.is-active { background: var(--jm-gold-500); color: var(--jm-blue-900); border-color: var(--jm-gold-500); }

/* ---------- Risk / fine print ---------- */
.fineprint { font-size: 13px; line-height: 1.65; color: var(--text-invert-muted); }
.surf-paper .fineprint, .surf-white .fineprint, .surf-light .fineprint { color: var(--text-body-muted); }
.fineprint--hero { max-width: 640px; border-top: 1px solid var(--border-invert-hairline); padding-top: 18px; margin-top: 36px; }

/* ---------- FAQ accordion ---------- */
.faq { border-top: 1px solid var(--border-invert-hairline); }
.surf-paper .faq, .surf-white .faq, .surf-light .faq { border-color: var(--border-hairline); }
.faq-item { border-bottom: 1px solid var(--border-invert-hairline); }
.surf-paper .faq-item, .surf-white .faq-item, .surf-light .faq-item { border-color: var(--border-hairline); }
.faq-q {
  width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 24px;
  padding: 26px 0; text-align: left; font-size: clamp(1.05rem, 1.6vw, 21px);
  font-variation-settings: var(--fv-regular); color: #fff;
}
.surf-paper .faq-q, .surf-white .faq-q, .surf-light .faq-q { color: var(--text-title); }
.faq-q .pm { flex-shrink: 0; width: 22px; height: 22px; position: relative; }
.faq-q .pm::before, .faq-q .pm::after { content: ""; position: absolute; background: var(--jm-gold-500); transition: transform var(--dur-base) var(--ease-standard); }
.faq-q .pm::before { top: 50%; left: 0; width: 100%; height: 1.5px; transform: translateY(-50%); }
.faq-q .pm::after { left: 50%; top: 0; width: 1.5px; height: 100%; transform: translateX(-50%); }
.faq-q[aria-expanded="true"] .pm::after { transform: translateX(-50%) scaleY(0); }
.faq-a { overflow: hidden; max-height: 0; transition: max-height var(--dur-slow) var(--ease-standard); }
.faq-a-inner { padding-bottom: 28px; max-width: 70ch; color: var(--text-invert); }
.surf-paper .faq-a-inner, .surf-white .faq-a-inner, .surf-light .faq-a-inner { color: var(--text-body); }

/* ---------- Forms ---------- */
.field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; }
.field label { font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-invert-muted); font-variation-settings: var(--fv-medium); }
.surf-paper .field label, .surf-white .field label, .surf-light .field label { color: var(--text-body-muted); }
.input, .select, .textarea {
  width: 100%; background: var(--bg-invert-deep); border: 1px solid var(--border-invert-muted);
  color: #fff; padding: 14px 16px; font: inherit; font-size: 16px; border-radius: var(--radius-xs);
  transition: border-color var(--dur-base) var(--ease-standard);
}
.surf-paper .input, .surf-paper .select, .surf-paper .textarea,
.surf-white .input, .surf-white .select, .surf-white .textarea {
  background: #fff; color: var(--text-title); border-color: var(--border-muted);
}
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--jm-gold-500); }
.input::placeholder, .textarea::placeholder { color: var(--text-invert-muted); }
.surf-paper .input::placeholder, .surf-paper .textarea::placeholder { color: var(--text-placeholder); }
.textarea { min-height: 140px; resize: vertical; }
.field-row { display: grid; gap: 20px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .field-row { grid-template-columns: 1fr 1fr; } }
.consent { display: flex; gap: 12px; align-items: flex-start; font-size: 13px; color: var(--text-invert-muted); }
.consent input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--jm-gold-500); }

/* scheduling embed (Google Calendar appointment schedule) */
.cal-embed { border: 0; width: 100%; height: 680px; display: block; background: #fff; }
@media (max-width: 600px) { .cal-embed { height: 760px; } }

/* inline newsletter */
.newsletter-form { display: flex; gap: 12px; flex-wrap: wrap; max-width: 520px; }
.newsletter-form .input { flex: 1; min-width: 220px; }

/* ---------- Logo strip / trust row ---------- */
.trust-row { display: flex; flex-wrap: wrap; gap: 14px 32px; align-items: center; }
.trust-row .item { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-invert-muted); }
.trust-row .item .ic { color: var(--jm-gold-500); }

/* ---------- Insights cards ---------- */
.post-card { display: flex; flex-direction: column; gap: 0; height: 100%; }
.post-thumb { aspect-ratio: 16 / 10; background: linear-gradient(135deg, var(--jm-blue-850), var(--jm-blue-950)); position: relative; overflow: hidden; border: 1px solid var(--border-invert-hairline); }
.post-thumb .stencil-mark { position: absolute; right: -10%; bottom: -20%; width: 60%; color: rgba(167,160,108,0.16); }
.post-thumb .topic { position: absolute; top: 14px; left: 14px; }
.post-body { padding: 22px 0 0; display: flex; flex-direction: column; flex: 1; }
.post-body .date { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-invert-muted); }
.post-body h3 { margin: 10px 0; font-size: clamp(1.2rem, 2vw, 24px); line-height: 1.2; }
.post-body p { color: var(--text-invert); font-size: 15px; }
.post-body .card-foot { margin-top: auto; padding-top: 18px; }

/* featured post */
.featured { display: grid; gap: clamp(24px, 4vw, 48px); grid-template-columns: 1fr; align-items: center; }
@media (min-width: 900px) { .featured { grid-template-columns: 1.1fr 1fr; } }
.featured .post-thumb { aspect-ratio: 3 / 2; }

/* ---------- Team ---------- */
.team-grid { display: grid; gap: 1px; background: var(--border-invert-hairline); border: 1px solid var(--border-invert-hairline); grid-template-columns: 1fr; }
@media (min-width: 600px) { .team-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 980px) { .team-grid { grid-template-columns: repeat(3, 1fr); } }
.team-member { background: var(--bg-invert); padding: 0; }
.team-member .tm-photo { margin: 0; }
.team-member .tm-body { padding: 22px 24px 26px; }
.team-member .role { color: var(--text-brand); font-size: 13px; letter-spacing: .06em; text-transform: uppercase; font-variation-settings: var(--fv-medium); }
.team-member h4 { margin: 6px 0 10px; }
.team-member p { font-size: 14px; color: var(--text-invert); }

/* ---------- Image frame + branded placeholder ---------- */
.img-frame { position: relative; overflow: hidden; margin: 0; background: var(--jm-blue-850); display: grid; place-items: center; }
.img-frame img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.img-frame.is-placeholder { background: linear-gradient(150deg, var(--jm-blue-850), var(--bg-invert-deep)); border: 1px solid var(--border-invert-hairline); }
.img-frame .img-ph-stencil { position: absolute; right: -10%; bottom: -12%; width: 60%; line-height: 0; opacity: .07; color: #fff; }
.img-frame .img-ph-stencil svg { width: 100%; height: auto; display: block; }
.img-frame .img-ph-initials { position: relative; font-family: var(--font-display); font-variation-settings: var(--fv-display); font-size: clamp(30px, 5vw, 46px); letter-spacing: .04em; color: var(--jm-gold-500); }
.img-frame .img-ph-label { position: relative; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--text-invert-muted); }
.img-frame--wide { width: 100%; }

/* ---------- Advisor card (Contact) ---------- */
.advisor-card { display: flex; gap: 20px; align-items: center; padding-bottom: 26px; margin-bottom: 26px; border-bottom: 1px solid var(--border-invert-hairline); }
.advisor-card__photo { width: 112px; flex: 0 0 112px; }
.advisor-card__meta .role-line { color: var(--text-brand); font-size: 13px; letter-spacing: .06em; text-transform: uppercase; font-variation-settings: var(--fv-medium); margin-top: 2px; }
.advisor-card__meta > p:last-child { font-size: 14px; color: var(--text-invert); }
@media (max-width: 420px) { .advisor-card { gap: 16px; } .advisor-card__photo { width: 92px; flex-basis: 92px; } }

/* ---------- Click-to-load embed (consent gate) ---------- */
.embed-gate { display: block; width: 100%; }
.embed-ph { position: relative; overflow: hidden; min-height: 360px; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 16px; padding: clamp(20px, 3vw, 30px); background: linear-gradient(150deg, var(--jm-blue-850), var(--bg-invert-deep)); border: 1px solid var(--border-invert-hairline); }
.embed-ph__stencil { position: absolute; right: -8%; bottom: -12%; width: 46%; color: #fff; opacity: .06; line-height: 0; }
.embed-ph__stencil svg { width: 100%; height: auto; display: block; }
.embed-ph__txt { position: relative; margin: 0; font-size: 14px; line-height: 1.5; color: var(--text-invert-muted); max-width: 320px; }
.embed-ph .btn { position: relative; appearance: none; -webkit-appearance: none; font: inherit; cursor: pointer; }

/* ---------- Cookie consent ---------- */
.consent-root { position: fixed; z-index: 1000; left: 0; right: 0; bottom: 0; display: flex; justify-content: flex-start; padding: clamp(12px, 2vw, 22px); pointer-events: none; }
.consent-card { pointer-events: auto; background: var(--bg-invert-deep); color: var(--text-invert); border: 1px solid var(--border-invert-hairline); max-width: 440px; width: 100%; padding: clamp(18px, 2.4vw, 26px); box-shadow: 0 18px 50px rgba(0,0,0,.4); }
.consent-eyebrow { color: var(--text-brand); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; font-variation-settings: var(--fv-medium); margin: 0 0 10px; }
.consent-text { font-size: 14px; line-height: 1.55; color: var(--text-invert); margin: 0; }
.consent-text a { color: var(--text-brand); text-decoration: underline; }
.consent-prefs { margin-top: 16px; display: grid; gap: 12px; }
.consent-row { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; }
.consent-row input { margin-top: 3px; width: 16px; height: 16px; flex: 0 0 auto; accent-color: var(--jm-gold-500); }
.consent-row__txt { display: block; font-size: 13px; line-height: 1.45; }
.consent-row__txt strong { display: block; color: #fff; font-variation-settings: var(--fv-medium); }
.consent-row__txt span { color: var(--text-invert-muted); }
.consent-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 18px; }
.consent-btn { font: inherit; font-size: 13px; letter-spacing: .04em; text-transform: uppercase; padding: 11px 18px; border: 1px solid transparent; cursor: pointer; background: none; color: var(--text-invert); }
.consent-btn--gold { background: var(--jm-gold-500); color: #1C262C; font-variation-settings: var(--fv-medium); }
.consent-btn--ghost { border-color: var(--border-invert-hairline); color: #fff; }
.consent-btn--link { color: var(--text-invert-muted); text-decoration: underline; padding-left: 4px; padding-right: 4px; }
.consent-btn--gold:hover { filter: brightness(1.06); }
.consent-btn--ghost:hover { border-color: var(--jm-gold-500); }
@media (max-width: 560px) { .consent-root { padding: 10px; } .consent-card { max-width: none; } .consent-actions .consent-btn--gold, .consent-actions .consent-btn--ghost { flex: 1 1 auto; text-align: center; } }

/* ---------- Blog: cards (cover images + linked thumbs) ---------- */
.post-thumb { display: block; }
.post-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.post-body h3 a { color: inherit; }
.post-body h3 a:hover { color: var(--text-brand); }
.post-card .post-thumb, .featured .post-thumb { transition: opacity .2s var(--ease-standard); }
.post-card:hover .post-thumb { opacity: .92; }
.topic-filter .chip { cursor: pointer; }
.post-grid .post-card[hidden] { display: none; }

/* ---------- Blog: article page ---------- */
.article-head { padding-bottom: clamp(28px, 4vw, 44px); }
.article-back { font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-invert-muted); display: inline-block; }
.article-back::before { content: "← "; }
.article-back:hover { color: var(--text-brand); }
.article-meta { font-size: 14px; color: var(--text-invert-muted); }
.article-cover { margin: clamp(-40px, -4vw, -24px) 0 0; position: relative; z-index: 1; border: 1px solid var(--border-hairline); overflow: hidden; aspect-ratio: 16 / 8; }
.article-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* article prose — long-form on a light surface */
.article-prose { max-width: 72ch; margin-inline: auto; }
.article-prose > * { max-width: none; }
.article-prose h2 { font-size: clamp(1.4rem, 2.6vw, 28px); margin: 1.6em 0 .5em; line-height: 1.2; }
.article-prose h3 { font-size: clamp(1.15rem, 2vw, 21px); margin: 1.4em 0 .4em; }
.article-prose p { font-size: 17px; line-height: 1.7; margin-bottom: 1.1em; }
.article-prose ul, .article-prose ol { margin: 0 0 1.2em; padding-left: 1.2em; }
.article-prose li { font-size: 17px; line-height: 1.7; margin-bottom: .4em; }
.article-prose li::marker { color: var(--jm-gold-600, #8C8654); }
.article-prose a { color: var(--text-brand-on-light); text-decoration: underline; text-underline-offset: 2px; }
.article-prose strong { font-variation-settings: var(--fv-semibold); }
.article-prose blockquote { margin: 1.6em 0; padding: 6px 0 6px 22px; border-left: 2px solid var(--jm-gold-500); font-family: var(--font-display); font-variation-settings: var(--fv-display); font-size: clamp(1.3rem, 2.4vw, 26px); line-height: 1.3; color: var(--text-body-focused); }
.article-prose .post-figure { margin: 1.8em 0; }
.article-prose .post-figure img { width: 100%; height: auto; display: block; border: 1px solid var(--border-hairline); }
.article-prose .post-figure figcaption { margin-top: 10px; font-size: 13px; color: var(--text-body-muted); }

/* ---------- CTA band ---------- */
.cta-band { position: relative; overflow: hidden; }
.cta-band .stencil-bg { color: var(--jm-blue-850); opacity: .5; }

/* ---------- Footer ---------- */
.site-footer { background: var(--bg-invert-deep); border-top: 1px solid var(--border-invert-hairline); padding-block: clamp(48px, 7vw, 88px) 40px; }
.footer-top { display: grid; gap: 40px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .footer-top { grid-template-columns: 1.4fr 1fr 1fr; } }
@media (min-width: 1040px) { .footer-top { grid-template-columns: 1.6fr 1fr 1fr 1fr; } }
.footer-col h5 { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--text-invert-muted); margin-bottom: 18px; }
.footer-col ul li { margin-bottom: 12px; }
.footer-col ul a { font-size: 15px; color: var(--text-invert); transition: color var(--dur-fast); }
.footer-col ul a:hover { color: #fff; }
.footer-brand .logo-lockup { margin-bottom: 20px; }
.footer-brand p { font-size: 14px; color: var(--text-invert-muted); max-width: 34ch; }
.footer-legal { margin-top: 48px; padding-top: 28px; border-top: 1px solid var(--border-invert-hairline); display: grid; gap: 16px; }
.footer-legal .reg-block { font-size: 13px; color: var(--text-invert-muted); line-height: 1.7; }
.footer-legal .reg-block strong { color: var(--text-invert); font-variation-settings: var(--fv-medium); }
.footer-fine { font-size: 12px; color: var(--text-invert-muted); line-height: 1.7; }
.footer-bottom { margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--border-invert-hairline); display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between; align-items: center; }
.footer-bottom .links { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.footer-bottom .links a { font-size: 13px; color: var(--text-invert-muted); display: inline-block; padding: 4px 0; }
.footer-bottom .links a:hover { color: #fff; }
.footer-bottom .copy { font-size: 13px; color: var(--text-invert-muted); }

/* ---------- Misc ---------- */
.lede-block p + p { margin-top: 20px; }
.prose p { margin-bottom: 18px; max-width: 68ch; color: var(--text-invert); }
.surf-paper .prose p, .surf-white .prose p, .surf-light .prose p { color: var(--text-body); }
.prose p:last-child { margin-bottom: 0; }
.divider-num { display: flex; align-items: baseline; gap: 16px; margin-bottom: 26px; }
.eyebrow-gold { color: var(--text-brand); }

.skip-link { position: absolute; left: -9999px; }
.skip-link:focus { left: 16px; top: 16px; z-index: 200; background: var(--jm-gold-500); color: var(--jm-blue-900); padding: 10px 16px; }

/* ---------- Visible keyboard focus (WCAG 2.4.7) — keyboard only, no effect on mouse use ---------- */
:focus-visible { outline: 2px solid var(--jm-gold-500); outline-offset: 2px; border-radius: 1px; }
.surf-paper :focus-visible, .surf-light :focus-visible, .surf-white :focus-visible { outline-color: var(--text-brand-on-light); }
.input:focus-visible, .select:focus-visible, .textarea:focus-visible { outline: 2px solid var(--jm-gold-500); outline-offset: 1px; }
.surf-paper .input:focus-visible, .surf-light .input:focus-visible,
.surf-paper .select:focus-visible, .surf-light .select:focus-visible,
.surf-paper .textarea:focus-visible, .surf-light .textarea:focus-visible { outline-color: var(--text-brand-on-light); }

/* reduce motion */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* reveal on scroll — progressive enhancement.
   Hidden state only applies when JS adds .js-reveal to <html>, so content
   is always visible without JS (e.g. when imported into Framer). */
html.js-reveal .reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s var(--ease-standard), transform .6s var(--ease-standard); }
html.js-reveal .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { html.js-reveal .reveal { opacity: 1; transform: none; } }

/* ============================================================
   APP PAGE — device mockups, store badges, QR cards
   Phone screens mirror the REAL client app UI (Expo/React-Native):
   dark navy theme, light-blue accents, Almarena Neue. Palette copied
   from the app's ThemeContext (dark). If the app is rebranded, re-skin
   the `--a-*` vars below. Numbers are illustrative (sample account).
   ============================================================ */
.app-stage { display: flex; justify-content: center; }
.app-phone {
  position: relative; flex: none;
  width: min(286px, 80vw); aspect-ratio: 9 / 19.3;
  background: #0E1418; border-radius: 40px; padding: 9px;
  box-shadow: var(--shadow-dark), 0 0 0 1px rgba(255,255,255,.06) inset;
}
.app-phone::before { /* notch */
  content: ""; position: absolute; z-index: 3; top: 14px; left: 50%;
  transform: translateX(-50%); width: 38%; height: 20px;
  background: #0E1418; border-radius: 0 0 16px 16px;
}
.app-screen {
  /* real-app palette (ThemeContext.dark) */
  --a-card: #121E2E; --a-line: #1D3352;
  --a-blue: #518AE0; --a-btn: #99C2FF; --a-btn-ink: #040B14;
  --a-txt: #FFFFFF; --a-sec: #ABC0E0; --a-dim: #7C8CA3;
  --a-green: #25B87D; --a-red: #BF1332;
  position: relative; height: 100%; border-radius: 32px; overflow: hidden;
  background: radial-gradient(125% 75% at 72% -8%, #16294A 0%, #0A1426 46%, #040B14 100%);
  color: var(--a-txt);
  display: flex; flex-direction: column;
  font-family: var(--font-text); font-variation-settings: var(--fv-regular);
}
.aps-bar { display: flex; align-items: center; justify-content: space-between; padding: 34px 18px 8px; }
.aps-bar .mark { width: 24px; height: 15px; color: var(--a-txt); opacity: .92; display: block; }
.aps-bar .mark svg { width: 100%; height: 100%; display: block; }
.aps-bar .hi { font-size: 13px; color: var(--a-txt); font-variation-settings: var(--fv-medium); }
.aps-bell { width: 30px; height: 30px; border-radius: 50%; background: var(--a-card); border: 1px solid var(--a-line); display: flex; align-items: center; justify-content: center; color: var(--a-sec); }
.aps-body { flex: 1; padding: 4px 16px 0; display: flex; flex-direction: column; gap: 18px; overflow: hidden; }

/* Home — centered portfolio header */
.aps-portfolio { display: flex; flex-direction: column; align-items: center; gap: 6px; margin-top: 10px; }
.aps-plabel { font-size: 13px; color: var(--a-sec); }
.aps-pvalue { font-family: var(--font-text); font-variation-settings: var(--fv-medium); font-size: 40px; line-height: 1.05; color: var(--a-txt); }
.aps-pchange { display: flex; align-items: center; gap: 6px; font-size: 12.5px; }
.aps-pchange .up { color: var(--a-green); font-variation-settings: var(--fv-medium); }
.aps-pchange .dim { color: var(--a-sec); }

/* Home — TWR line graph */
.aps-graph { width: 100%; height: 96px; display: block; }

/* Home — analytics grid */
.aps-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.aps-gcard { background: var(--a-card); border-radius: 4px; padding: 16px 14px; display: flex; flex-direction: column; gap: 12px; }
.aps-gcard .ico { color: var(--a-blue); }
.aps-gcard .gt { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.aps-gcard .gt b { font-size: 13px; font-variation-settings: var(--fv-medium); color: var(--a-txt); }
.aps-gcard .badge { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: rgba(81,138,224,.16); color: var(--a-blue); font-size: 12px; font-variation-settings: var(--fv-medium); display: flex; align-items: center; justify-content: center; }
.aps-gcard .view { display: flex; align-items: center; justify-content: center; gap: 5px; font-size: 11px; color: var(--a-sec); }

/* Onboarding — steps */
.aps-h { font-family: var(--font-text); font-variation-settings: var(--fv-medium); font-size: 22px; margin-top: 4px; }
.aps-steps { display: flex; flex-direction: column; gap: 14px; margin-top: 4px; }
.aps-step { display: flex; align-items: center; gap: 12px; font-size: 13px; }
.aps-step .n { flex: none; width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-variation-settings: var(--fv-medium); }
.aps-step.done .n { background: var(--a-green); color: #04140C; }
.aps-step.now .n { background: var(--a-blue); color: #fff; }
.aps-step.next .n { background: var(--a-card); color: var(--a-dim); border: 1px solid var(--a-line); }
.aps-step .t b { display: block; font-variation-settings: var(--fv-medium); color: var(--a-txt); }
.aps-step .t span { color: var(--a-sec); font-size: 12px; }
.aps-card { background: var(--a-card); border: 1px solid var(--a-line); border-radius: 4px; padding: 14px; margin-top: 2px; }
.aps-card .h { font-size: 13px; font-variation-settings: var(--fv-medium); color: var(--a-txt); }
.aps-card .s { font-size: 12px; color: var(--a-sec); margin-top: 4px; line-height: 1.5; }
.aps-btn { width: 100%; border: 0; border-radius: 4px; background: var(--a-btn); color: var(--a-btn-ink); font-family: var(--font-text); font-variation-settings: var(--fv-medium); font-size: 14px; padding: 13px 16px; display: flex; align-items: center; justify-content: center; gap: 8px; }

/* Advisor — profile */
.aps-advisor { flex: 1; display: flex; flex-direction: column; }
.aps-photo { position: relative; height: 286px; margin: 0; background: linear-gradient(155deg, #24395C 0%, #131F33 55%, #0A1322 100%); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.aps-photo .sil { width: 88px; height: 88px; color: rgba(171,192,224,.22); }
.aps-photo .ov { position: absolute; left: 0; right: 0; bottom: 0; padding: 16px 18px; background: linear-gradient(180deg, rgba(4,11,20,0) 0%, rgba(4,11,20,.82) 100%); }
.aps-photo .ov .lbl { font-size: 12px; color: var(--a-sec); }
.aps-photo .ov .nm { font-family: var(--font-text); font-variation-settings: var(--fv-medium); font-size: 26px; color: var(--a-txt); margin: 2px 0 12px; }
.aps-about { padding: 16px 18px 0; }
.aps-about h5 { font-size: 16px; font-variation-settings: var(--fv-medium); color: var(--a-txt); margin-bottom: 8px; }
.aps-about p { font-size: 12.5px; line-height: 1.6; color: var(--a-sec); }

/* Bottom tab bar (5 tabs) */
.aps-tabs { margin-top: auto; display: flex; justify-content: space-between; padding: 9px 12px 18px; background: #040B14; border-top: 1px solid var(--a-line); }
.aps-tabs .tab { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 9px; letter-spacing: .02em; color: var(--a-dim); }
.aps-tabs .tab svg { width: 19px; height: 19px; }
.aps-tabs .tab.on { color: var(--a-blue); }

.app-illus { margin-top: 16px; text-align: center; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--text-invert-muted); }
.surf-paper .app-illus, .surf-light .app-illus { color: var(--text-body-muted); }

/* Store badges (App Store / Google Play) */
.store-badges { display: flex; flex-wrap: wrap; gap: 12px; }
.store-badge { display: inline-flex; align-items: center; gap: 11px; padding: 10px 18px; border-radius: 10px; background: var(--jm-blue-900); color: #fff; border: 1px solid var(--jm-blue-900); transition: background var(--dur-fast), border-color var(--dur-fast); }
.store-badge:hover { background: var(--jm-blue-850); border-color: var(--jm-gold-500); }
.store-badge svg { width: 22px; height: 24px; flex: none; }
.store-badge .sb-t { display: flex; flex-direction: column; line-height: 1.15; text-align: left; }
.store-badge .sb-t small { font-size: 10px; letter-spacing: .04em; text-transform: uppercase; opacity: .72; }
.store-badge .sb-t b { font-size: 15px; font-variation-settings: var(--fv-medium); }
.surf-ink .store-badge, .surf-deep .store-badge { background: #fff; color: var(--jm-blue-900); border-color: #fff; }
.surf-ink .store-badge:hover, .surf-deep .store-badge:hover { background: var(--jm-beige-50); border-color: var(--jm-gold-500); }

/* QR download cards */
.qr-grid { display: grid; gap: 18px; grid-template-columns: 1fr; }
@media (min-width: 680px) { .qr-grid { grid-template-columns: 1fr 1fr; } }
.qr-card { display: flex; align-items: center; gap: 18px; padding: 22px; border: 1px solid var(--border-invert-hairline); background: var(--bg-invert-raised); }
.qr-card .qr { flex: none; width: 110px; height: 110px; background: #fff; padding: 11px; border-radius: 4px; }
.qr-card .qr img { width: 100%; height: 100%; display: block; }
.qr-card .qr-t h4 { margin: 0; }
.qr-card .qr-t p { font-size: 13px; color: var(--text-invert-muted); margin-top: 6px; line-height: 1.5; }
.qr-card .qr-t .store-badge { margin-top: 12px; }

/* ---------- Forms: honeypot, status message, busy state ---------- */
.hp-field { position: absolute !important; left: -9999px; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.form-status { font-size: 14px; line-height: 1.5; margin-top: 14px; }
.form-status.is-ok { color: #2FB57D; }   /* readable green on dark surfaces */
.form-status.is-err { color: #FF6B6B; }
.surf-paper .form-status.is-ok, .surf-light .form-status.is-ok { color: var(--jm-green-500); }
.surf-paper .form-status.is-err, .surf-light .form-status.is-err { color: var(--jm-red-500); }
.btn[disabled] { opacity: .6; cursor: default; pointer-events: none; }

/* ---- Legal document index (grouped list, replaces card grid) ---- */
.doc-index { max-width: 920px; display: grid; gap: clamp(30px, 4.5vw, 48px); }
.doc-group__label {
  margin: 0 0 2px; padding-bottom: 12px;
  font-size: .78rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  color: var(--text-brand);
  border-bottom: 1px solid var(--border-invert-muted);
}
.doc-list { list-style: none; margin: 0; padding: 0; }
.doc-row { border-bottom: 1px solid var(--border-invert-hairline); }
.doc-row:last-child { border-bottom: 0; }
.doc-row__link {
  display: flex; align-items: baseline; gap: 18px;
  padding: 17px 6px; text-decoration: none;
  color: var(--text-title-invert);
  transition: color .15s ease, padding-left .15s ease;
}
.doc-row__link:hover, .doc-row__link:focus-visible { color: var(--text-brand); padding-left: 12px; }
.doc-row__name { flex: 1 1 auto; font-size: 1rem; line-height: 1.4; }
.doc-row__meta {
  flex: 0 0 auto; white-space: nowrap;
  font-size: .78rem; letter-spacing: .04em; color: var(--text-invert-muted);
}
.doc-row__dl {
  flex: 0 0 auto; display: inline-flex; align-items: center; gap: 7px;
  font-size: .8rem; letter-spacing: .02em; color: var(--text-invert-muted);
  transition: color .15s ease;
}
.doc-row__link:hover .doc-row__dl, .doc-row__link:focus-visible .doc-row__dl { color: var(--text-brand); }
.doc-row__icon { display: block; flex: 0 0 auto; }
@media (max-width: 560px) {
  .doc-row__link { flex-wrap: wrap; gap: 4px 14px; padding: 15px 6px; }
  .doc-row__name { flex: 1 1 100%; }
  .doc-row__dl { margin-left: auto; }
}
