/* Mercator Investment Management — static theme.
   Restrained Salient-inspired palette: deep navy/charcoal + gold/copper,
   editorial serif display headings, clean sans body. No build step. */

:root {
  --navy: #0e1620;
  --navy-deep: #0a1017;
  --charcoal: #1a2430;
  --gold: #c19a3f;
  --gold-soft: #d9b964;
  --paper: #f7f5f0;
  --ink: #232a33;
  --muted: #5d6670;
  --line: #e3ddd1;
  --white: #ffffff;
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
  font-size: 17px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}
main { flex: 1 0 auto; }
.site-header, .site-footer { flex: 0 0 auto; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--gold); }
:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: 2px; }

.wrap { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.prose { max-width: 760px; }

/* ---------- Header ---------- */
.site-header {
  background: var(--navy);
  position: sticky; top: 0; z-index: 50;
  border-bottom: 1px solid rgba(193,154,63,.25);
}
.header-inner {
  display: flex; align-items: center; justify-content: flex-end;
  gap: 24px; padding: 12px 28px 12px 16px; max-width: none;
}
.brand img { height: 78px; width: auto; }
.nav-toggle {
  display: none; background: none; border: 1px solid rgba(255,255,255,.35);
  color: #fff; border-radius: 6px; padding: 8px 14px; font-size: 15px; cursor: pointer;
}
.main-nav ul {
  list-style: none; margin: 0; padding: 0; display: flex; gap: 30px; align-items: center;
}
.main-nav a {
  color: #f2ede1; text-decoration: none; font-size: 14.5px; letter-spacing: .08em;
  text-transform: uppercase; padding: 6px 0; border-bottom: 2px solid transparent;
}
.main-nav a:hover, .main-nav a[aria-current="page"] {
  color: var(--gold-soft); border-bottom-color: var(--gold);
}
.main-nav .follow-link { color: var(--gold-soft); }

/* ---------- Follow page ---------- */
.follow-list { list-style: none; margin: 32px 0 0; padding: 0; display: grid; gap: 14px; }
.follow-list a {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 20px 24px; border: 1px solid rgba(193,154,63,.35); border-radius: 8px;
  text-decoration: none;
}
.follow-list a:hover { border-color: var(--gold); }
.follow-list .platform { font-size: 19px; font-weight: 600; color: var(--ink); }
.follow-list .handle { font-size: 14px; color: #8a8578; }
.empty-note { color: #8a8578; font-style: italic; margin-top: 8px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 92vh; display: flex; align-items: center;
  color: #fff; overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0;
  background: url("/assets/img/mercator-investments2.jpg") center center / cover no-repeat, var(--navy-deep);
}
.hero-veil {
  position: absolute; inset: 0;
  background: linear-gradient(100deg, rgba(5,8,12,.93) 0%, rgba(5,8,12,.72) 45%, rgba(5,8,12,.32) 100%);
}
.hero-content { position: relative; z-index: 1; padding: 96px 0; }
.hero-kicker {
  display: inline-block; font-size: 13px; letter-spacing: .22em; text-transform: uppercase;
  color: var(--gold-soft); margin-bottom: 22px;
  border-left: 3px solid var(--gold); padding-left: 14px;
}
.hero h1 {
  font-family: var(--serif); font-weight: 500; font-size: clamp(2.2rem, 5.2vw, 4rem);
  line-height: 1.12; max-width: 20ch; margin: 0 0 26px;
}
.hero p.lede { font-size: 20px; line-height: 1.6; max-width: 38ch; color: #e9e2d2; margin: 0 0 36px; }
.btn {
  display: inline-block; text-decoration: none; font-size: 14px; letter-spacing: .12em;
  text-transform: uppercase; color: #0b0e12; background: var(--gold);
  padding: 15px 34px; border-radius: 2px; border: 1px solid var(--gold);
  transition: background .2s ease, color .2s ease;
}
.btn:hover { background: transparent; color: var(--gold-soft); }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); margin-left: 12px; }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold-soft); }

/* ---------- Page hero (interior) ---------- */
.page-hero { background: var(--navy); color: #fff; padding: 84px 0 72px; position: relative; }
.page-hero::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: var(--gold); }
.page-hero h1 {
  font-family: var(--serif); font-weight: 500; font-size: clamp(2rem, 4.4vw, 3.2rem);
  margin: 0 0 10px; line-height: 1.15;
}
.page-hero .crumb { font-size: 13px; letter-spacing: .18em; text-transform: uppercase; color: var(--gold-soft); margin-bottom: 18px; }
.page-hero .standfirst { color: #d9d3c2; max-width: 60ch; margin: 0; }

/* ---------- Content sections ---------- */
.section { padding: 88px 0; }
.two-col { display: grid; grid-template-columns: 5fr 7fr; gap: 64px; align-items: start; }
.two-col img.framed {
  border-radius: 3px; box-shadow: 0 24px 60px rgba(14,22,32,.22);
}
h2.page-h { font-family: var(--serif); font-weight: 500; font-size: clamp(1.8rem, 3.4vw, 2.6rem); margin: 0 0 8px; }
.rule { width: 56px; height: 2px; background: var(--gold); margin: 18px 0 26px; }
.prose p { margin: 0 0 1.35em; }
.prose p:last-child { margin-bottom: 0; }

/* ---------- Team ---------- */
.member { padding: 44px 0; }
.member + .member { border-top: 1px solid var(--line); }
.member h2 { font-family: var(--serif); font-weight: 500; font-size: 2.1rem; margin: 0; }
.member h3 { font-size: 15px; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin: 8px 0 20px; font-weight: 600; }
.expander-btn {
  background: none; border: none; padding: 0; cursor: pointer; font: inherit;
  color: var(--gold); font-weight: 600; letter-spacing: .04em; margin-top: 14px;
}
.expander-btn:hover { text-decoration: underline; }
.expander-body[hidden] { display: none; }

/* ---------- Insights ---------- */
.post-card {
  display: grid; grid-template-columns: 420px 1fr; gap: 0; text-decoration: none; color: inherit;
  background: #fff; border: 1px solid var(--line); border-radius: 4px; overflow: hidden;
  transition: box-shadow .25s ease, transform .25s ease;
}
.post-card:hover { box-shadow: 0 18px 48px rgba(14,22,32,.16); transform: translateY(-3px); }
.post-card img { height: 100%; min-height: 280px; object-fit: cover; }
.post-card-body { padding: 44px 48px; }
.post-date { font-size: 13px; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); font-weight: 600; }
.post-card h2 { font-family: var(--serif); font-weight: 500; font-size: 1.9rem; line-height: 1.25; margin: 12px 0 14px; color: var(--navy); }
.post-card p.excerpt { color: var(--muted); margin: 0 0 18px; }
.post-card .read { color: var(--navy); font-weight: 600; font-size: 14px; letter-spacing: .1em; text-transform: uppercase; }

/* ---------- Article ---------- */
.article { padding: 76px 0 96px; }
.article-meta { font-size: 13px; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); font-weight: 600; margin-bottom: 14px; }
.article h1 { font-family: var(--serif); font-weight: 500; font-size: clamp(2rem, 4.4vw, 3.1rem); line-height: 1.16; margin: 0 0 34px; max-width: 24ch; }
.article .prose { max-width: 700px; }
.article .prose h2 { font-family: var(--serif); font-weight: 500; font-size: 1.7rem; margin: 2.1em 0 .6em; color: var(--navy); }
.back-link { display: inline-block; margin-top: 56px; color: var(--navy); font-weight: 600; text-decoration: none; font-size: 15px; letter-spacing: .06em; }
.back-link:hover { color: var(--gold); }

/* ---------- Forms ---------- */
.form-card { background: #fff; border: 1px solid var(--line); border-radius: 4px; padding: 48px; box-shadow: 0 12px 40px rgba(14,22,32,.08); }
.field { margin-bottom: 22px; }
.field label { display: block; font-size: 14px; font-weight: 600; letter-spacing: .04em; margin-bottom: 8px; }
.field label .req { color: #a03434; }
.field input, .field textarea {
  width: 100%; font: inherit; padding: 13px 15px; border: 1px solid #cfc9ba; border-radius: 3px; background: #fffdf8;
}
.field input:focus, .field textarea:focus { border-color: var(--gold); outline: 2px solid rgba(193,154,63,.35); }
.field textarea { min-height: 150px; resize: vertical; }
.hp { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.form-note { font-size: 14.5px; color: var(--muted); margin-top: 18px; }
.form-status { border-radius: 3px; padding: 16px 20px; margin-bottom: 24px; font-size: 15.5px; }
.form-status.ok { background: #eef4ea; border: 1px solid #9dbd8f; color: #2f4a26; }
.form-status.err { background: #f9ecec; border: 1px solid #d39292; color: #6b2222; }
.btn-row button.btn { cursor: pointer; font-family: var(--sans); }

/* ---------- Client login demo ---------- */
.demo-banner {
  background: #5c3d00; color: #ffe9bd; border: 2px dashed #e0a93e; border-radius: 4px;
  padding: 14px 20px; font-size: 15px; font-weight: 600; margin-bottom: 28px;
}
.demo-banner strong { text-transform: uppercase; letter-spacing: .1em; }
.login-card { max-width: 460px; margin: 0 auto; background: #fff; border: 1px solid var(--line); border-radius: 4px; padding: 44px; box-shadow: 0 12px 40px rgba(14,22,32,.08); }
.client-area { display: none; }
.client-area .empty {
  border: 1px dashed #b9b2a2; border-radius: 4px; padding: 40px; text-align: center; color: var(--muted);
}

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-deep); color: #b9b3a4; padding: 64px 0 40px; font-size: 14.5px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 48px; margin-bottom: 48px; }
.footer-grid h4 { color: #fff; font-size: 13px; letter-spacing: .18em; text-transform: uppercase; margin: 0 0 16px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: 10px; }
.footer-grid a { color: #d9d3c2; text-decoration: none; }
.footer-grid a:hover { color: var(--gold-soft); }
.footer-brand img { height: 72px; width: auto; margin-bottom: 16px; }
.footer-legal { border-top: 1px solid rgba(255,255,255,.12); padding-top: 26px; display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; font-size: 13.5px; }
.footer-legal a { color: var(--gold-soft); }

/* ---------- 404 ---------- */
.center-404 { text-align: center; padding: 110px 0; }
.center-404 h1 { font-family: var(--serif); font-size: clamp(3rem, 8vw, 6rem); margin: 0 0 10px; color: var(--navy); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .two-col { grid-template-columns: 1fr; gap: 40px; }
  .post-card { grid-template-columns: 1fr; }
  .post-card img { min-height: 0; max-height: 300px; }
  .post-card-body { padding: 30px; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .form-card, .login-card { padding: 30px 24px; }
}
@media (max-width: 760px) {
  .nav-toggle { display: inline-block; }
  .main-nav { display: none; width: 100%; }
  .main-nav.open { display: block; }
  .header-inner { flex-wrap: wrap; }
  .main-nav ul { flex-direction: column; align-items: flex-start; gap: 4px; padding: 12px 0 6px; }
  .main-nav li { width: 100%; }
  .main-nav a { display: block; padding: 10px 0; }
  .section { padding: 60px 0; }
  .hero { min-height: 78vh; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
