/* ================================================================
   FMAdvisory — shared design system
   Source of truth: real-estate.html. Page-specific styles stay
   inline in each page's own <style>, loaded after this file.
   ================================================================ */

/* ============================================================
   FONTS — Inter, self-hosted (variable woff2, latin + latin-ext)
============================================================ */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('fonts/inter-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('fonts/inter-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter';
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url('fonts/inter-italic-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url('fonts/inter-italic-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ============================================================
   TOKENS
============================================================ */
:root {
  --navy-950:    #07162C;
  --navy-900:    #0B1F3D;
  --navy-800:    #0F2748;
  --navy-700:    #173458;
  --navy-600:    #234470;
  --navy-500:    #355A8A;
  --navy-400:    #5C7DA8;
  --navy-300:    #8FA6C4;
  --navy-200:    #C2CFDF;
  --platinum-700:#565A62;
  --platinum-600:#6F737B;
  --platinum-500:#8B8F96;
  --platinum-400:#A8ACB2;
  --platinum-300:#C5C8CC;
  --platinum-200:#DDDFE2;
  --bone-100:    #FBFAF6;
  --bone-200:    #F5F2EA;
  --gold-700:    #8C6A1F;
  --gold-600:    #B8893A;
  --gold-500:    #D4A356;
  --gold-300:    #E8C994;
  --font-heading: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body:    "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --text-xs:    0.8125rem;
  --text-sm:    0.9375rem;
  --text-base:  1.0625rem;
  --text-lg:    1.1875rem;
  --text-xl:    1.375rem;
  --text-h3:    1.25rem;
  --text-h2:    clamp(1.625rem, 2.6vw, 2.125rem);
  --text-hero:  clamp(2.25rem, 4.4vw, 3.25rem);
  --text-price: 2.25rem;
  --section-y:  clamp(64px, 9vw, 112px);
  --max-w:      1160px;
  --gutter:     clamp(20px, 5vw, 48px);
  --radius:     10px;
  --line:       rgba(199,210,228,0.14);
  --line-soft:  rgba(199,210,228,0.08);
  --nav-h:      88px;
}

/* ============================================================
   BASE
============================================================ */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
/* Font safety net: only --font-heading and --font-body (both Inter) */
html, body, p, li, ul, span, a, small, label, input, textarea, select, button, div { font-family: var(--font-body); }
h1, h2, h3, h4, h5, h6, .btn, button, nav a, .badge, .price { font-family: var(--font-heading); }
body {
  background: var(--navy-950);
  color: var(--bone-100);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.65;
  min-height: 100vh;
  overflow-x: hidden;
}
img { max-width: 100%; }

/* Visible keyboard focus everywhere */
a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--gold-300);
  outline-offset: 3px;
  border-radius: var(--radius);
}

/* ============================================================
   LAYOUT
============================================================ */
/* Centred content column with side gutters */
.container {
  width: 100%;
  max-width: calc(var(--max-w) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 0 var(--gutter);
}
/* Standard vertical section rhythm */
.section { padding: var(--section-y) 0; }
/* Page wrapper: clears the fixed navbar */
.page { padding-top: var(--nav-h); }

/* ============================================================
   TYPOGRAPHY
============================================================ */
.eyebrow {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-heading);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-500);
  margin-bottom: 16px;
}
.section-title {
  font-family: var(--font-heading);
  font-size: var(--text-h2);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--bone-100);
  text-wrap: balance;
}

/* ============================================================
   BUTTONS
============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 24px;
  border-radius: var(--radius);
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background 200ms, border-color 200ms, color 200ms, transform 200ms;
}
.btn-primary {
  background: var(--gold-500);
  color: var(--navy-950);
  border: 1px solid var(--gold-500);
}
.btn-primary:hover {
  background: var(--gold-300);
  border-color: var(--gold-300);
  transform: translateY(-1px);
}
.btn-secondary {
  background: transparent;
  color: var(--bone-100);
  border: 1px solid rgba(199,210,228,0.34);
}
.btn-secondary:hover {
  border-color: var(--gold-500);
  background: rgba(255,255,255,0.04);
}

/* ============================================================
   FORMS
============================================================ */
.input {
  min-height: 48px;
  padding: 0 16px;
  border-radius: var(--radius);
  border: 1px solid rgba(199,210,228,0.30);
  background: rgba(255,255,255,0.04);
  color: var(--bone-100);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1;
}
.input::placeholder { color: var(--platinum-400); }
.input:focus { border-color: var(--gold-500); }

/* ============================================================
   NAVBAR
============================================================ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 100;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background 320ms cubic-bezier(0.2,0,0.2,1),
              border-color 320ms cubic-bezier(0.2,0,0.2,1),
              backdrop-filter 320ms cubic-bezier(0.2,0,0.2,1);
}
.nav.scrolled {
  background: rgba(7,22,44,0.72);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border-bottom-color: rgba(199,210,228,0.10);
}
.nav-inner {
  max-width: calc(var(--max-w) + 2 * var(--gutter));
  margin: 0 auto;
  height: 100%;
  padding: 0 var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.nav-logo { flex-shrink: 1; min-width: 0; }
.nav-logo img {
  height: 70px;
  max-width: 100%;
  display: block;
  border: none;
  object-fit: contain;
  object-position: left center;
}
.nav-links {
  display: flex;
  gap: 32px;
  align-items: center;
}
.nav-links a {
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--platinum-200);
  text-decoration: none;
  letter-spacing: 0;
  padding: 8px 0;
  transition: color 220ms;
  white-space: nowrap;
}
.nav-links a:hover { color: var(--bone-100); }
.nav-links a.nav-cta { padding: 0 24px; }
.nav-divider {
  width: 1px;
  height: 18px;
  background: rgba(199,210,228,0.18);
  flex-shrink: 0;
}
/* "Book a Call" outline button in the navbar */
.nav-cta {
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: 600;
  min-height: 48px;
  padding: 0 24px;
  border-radius: var(--radius);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  transition: all 220ms cubic-bezier(0.2,0,0.2,1);
  letter-spacing: 0;
  text-decoration: none;
  white-space: nowrap;
  line-height: 1;
  background: transparent;
  color: var(--bone-100);
  border: 1px solid rgba(199,210,228,0.30);
}
.nav-cta:hover {
  border-color: var(--gold-500);
  background: rgba(255,255,255,0.04);
}

.nav-burger {
  display: none;
  flex-shrink: 0;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--bone-100);
}
.nav-mobile {
  display: none;
  position: fixed;
  top: var(--nav-h); left: 0; right: 0;
  background: rgba(7,22,44,0.97);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  z-index: 99;
  padding: 24px var(--gutter) 32px;
  flex-direction: column;
  gap: 0;
  border-bottom: 1px solid rgba(199,210,228,0.10);
}
.nav-mobile.open { display: flex; }
.nav-mobile a {
  font-family: var(--font-heading);
  font-size: var(--text-base);
  font-weight: 500;
  color: var(--platinum-200);
  text-decoration: none;
  padding: 16px 0;
  border-bottom: 1px solid rgba(199,210,228,0.07);
  transition: color 180ms;
}
.nav-mobile a:hover { color: var(--bone-100); }
.nav-mobile a:last-child { border-bottom: none; }

@media (max-width: 1100px) {
  .nav-links { display: none; }
  .nav-burger { display: flex; }
}
@media (max-width: 760px) {
  .nav-logo img { height: 48px; }
}

/* ============================================================
   FOOTER
============================================================ */
.footer {
  background: var(--navy-950);
  border-top: 1px solid var(--line-soft);
}
.footer-inner {
  max-width: calc(var(--max-w) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 56px;
  padding-top: 64px;
  padding-bottom: 64px;
  border-bottom: 1px solid rgba(199,210,228,0.10);
}
.footer-logo {
  height: 56px;
  margin-bottom: 28px;
  display: block;
  border: none;
}
.footer-tagline {
  font-family: var(--font-body);
  font-size: var(--text-xl);
  line-height: 1.3;
  font-weight: 400;
  color: var(--bone-100);
  max-width: 360px;
  margin: 0;
  letter-spacing: 0;
}
.footer-tagline em { color: var(--gold-500); font-style: italic; }
.footer-sub {
  font-size: var(--text-sm);
  color: var(--platinum-300);
  font-family: var(--font-body);
  line-height: 1.65;
  display: block;
  margin-top: 16px;
  font-style: normal;
}
.footer-col-title {
  font-family: var(--font-heading);
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gold-500);
  margin-bottom: 24px;
}
.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.footer-links a {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--platinum-200);
  text-decoration: none;
  transition: color 220ms;
}
.footer-links a:hover { color: var(--bone-100); }
.footer-contact {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding-top: 32px;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: var(--platinum-300);
}
.footer-contact a {
  color: var(--platinum-300);
  text-decoration: none;
  transition: color 220ms;
}
.footer-contact a:hover { color: var(--bone-100); }
.footer-sep { color: var(--platinum-600); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 32px;
  padding-bottom: 40px;
  gap: 16px;
  flex-wrap: wrap;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: var(--platinum-400);
}

@media (max-width: 960px) {
  .footer-top { grid-template-columns: 1fr 1fr; gap: 40px; }
}
@media (max-width: 760px) {
  .footer-top { grid-template-columns: 1fr; gap: 40px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

/* ============================================================
   MOTION
   Hidden state only applies once site.js adds .motion-ready to
   <html>, so content stays visible if JavaScript fails.
============================================================ */
.motion-ready .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 500ms ease-out, transform 500ms ease-out;
}
.motion-ready .reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .motion-ready .reveal { opacity: 1; transform: none; transition: none; }
}

/* ============================================================
   COMPONENTS (added for index.html — v2)
============================================================ */
/* Surface card: hairline border, translucent navy fill */
.card {
  border: 1px solid var(--line);
  background: rgba(15,39,72,0.30);
  border-radius: var(--radius);
  overflow: hidden;
}
/* Two equal columns, stacked at 900px and below */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}
@media (max-width: 900px) {
  .grid-2 { grid-template-columns: 1fr; }
}
/* Gold text link with optional trailing icon */
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--gold-500);
  text-decoration: none;
  cursor: pointer;
  transition: color 200ms;
}
.text-link:hover { color: var(--gold-300); }
.text-link svg { flex-shrink: 0; transition: transform 200ms; }
.text-link:hover svg { transform: translateX(3px); }

/* Form field: label stacked over an .input */
.field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.field-label {
  font-family: var(--font-heading);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--platinum-400);
  transition: color 200ms;
}
.field:focus-within .field-label { color: var(--gold-500); }
textarea.input {
  padding: 12px 16px;
  line-height: 1.6;
  resize: vertical;
}
select.input {
  appearance: none;
  padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none' stroke='%238FA6C4' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  cursor: pointer;
}
select.input option { background: var(--navy-900); color: var(--bone-100); }
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid var(--gold-300);
  outline-offset: 3px;
}

/* ============================================================
   UTILITIES
============================================================ */
/* Visually hidden but available to screen readers and keyboard */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ============================================================
   NAVBAR — mobile menu "Book a Call" button (v3)
   Uses .btn .btn-primary; these rules only undo the plain
   .nav-mobile a link styling for this one item.
============================================================ */
.nav-mobile a.nav-mobile-cta {
  margin-top: 24px;
  width: 100%;
  min-height: 48px;
  padding: 0 24px;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--navy-950);
  border: 1px solid var(--gold-500);
}
.nav-mobile a.nav-mobile-cta:hover {
  color: var(--navy-950);
  border-color: var(--gold-300);
}

/* ============================================================
   NAVBAR — current page (v4)
============================================================ */
.nav-links a[aria-current="page"],
.nav-mobile a[aria-current="page"] { color: var(--gold-500); }
