/* ── RESET & BASE ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:      #EEEAE4;
  --navy:    #1A2340;
  --rose:    #B8887C;
  --lav:     #B0AACA;
  --dark:    #18182C;
  --gray:    #555566;
  --lgray:   #888898;
  --rule:    #C4C0BA;
  --card-bg: #E6E2DC;
  --white:   #FFFFFF;

  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans:  'Jost', system-ui, sans-serif;

  --max-w: 1160px;
  --pad-x: clamp(24px, 5vw, 80px);
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--dark);
  font-family: var(--font-sans);
  font-weight: 300;
  line-height: 1.6;
  overflow-x: hidden;
}

/* ── TYPOGRAPHY ───────────────────────────────────────── */
h1, h2, h3 { font-family: var(--font-serif); font-weight: 400; line-height: 1.15; }

/* ── NAV ──────────────────────────────────────────────── */
#nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 20px var(--pad-x);
  display: flex; align-items: center;
  transition: background 0.4s, box-shadow 0.4s;
}
#nav.scrolled {
  background: rgba(238,234,228,0.96);
  box-shadow: 0 1px 0 var(--rule);
  backdrop-filter: blur(8px);
}
.nav-inner {
  max-width: var(--max-w); width: 100%;
  margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-brand { display: flex; align-items: baseline; gap: 8px; }
.nav-logo { font-family: var(--font-serif); font-size: 1.35rem; font-weight: 500; color: var(--navy); }
.nav-sub { font-size: 0.7rem; color: var(--lgray); letter-spacing: 0.08em; text-transform: uppercase; }
.nav-links { display: flex; list-style: none; gap: 32px; align-items: center; }
.nav-links a { font-size: 0.82rem; color: var(--gray); text-decoration: none; letter-spacing: 0.04em; transition: color 0.2s; }
.nav-links a:hover { color: var(--navy); }
.nav-cta {
  border: 1px solid var(--rose); color: var(--rose) !important;
  padding: 7px 18px; border-radius: 2px;
  transition: background 0.2s, color 0.2s !important;
}
.nav-cta:hover { background: var(--rose); color: var(--white) !important; }

/* ── HERO ─────────────────────────────────────────────── */
#hero {
  min-height: 100vh;
  display: grid; grid-template-columns: 1fr 1fr;
  align-items: center;
  padding: 0 var(--pad-x);
  padding-top: max(160px, 20vh);
  padding-bottom: 80px;
  gap: 60px;
  max-width: var(--max-w); margin: 0 auto;
}

/* Ensure SVG is always visible */
#eigenSvg { display: block; overflow: visible; }
.eigen-visual { background: transparent; }
.hero-eyebrow {
  font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--rose); margin-bottom: 20px;
}
.hero-title {
  font-size: clamp(2.4rem, 4.5vw, 3.8rem);
  color: var(--navy); margin-bottom: 24px;
  font-weight: 400;
}
.hero-sub {
  font-size: 0.95rem; color: var(--gray);
  max-width: 440px; margin-bottom: 36px; line-height: 1.75;
}
.hero-actions { display: flex; gap: 16px; margin-bottom: 56px; flex-wrap: wrap; }
.btn-primary {
  background: var(--navy); color: var(--white);
  padding: 13px 28px; font-size: 0.82rem; letter-spacing: 0.06em;
  text-decoration: none; border-radius: 2px;
  transition: background 0.2s, transform 0.2s;
  font-family: var(--font-sans); font-weight: 400;
}
.btn-primary:hover { background: #253060; transform: translateY(-1px); }
.btn-ghost {
  border: 1px solid var(--rule); color: var(--gray);
  padding: 13px 28px; font-size: 0.82rem; letter-spacing: 0.06em;
  text-decoration: none; border-radius: 2px;
  transition: border-color 0.2s, color 0.2s;
  font-family: var(--font-sans); font-weight: 300;
}
.btn-ghost:hover { border-color: var(--navy); color: var(--navy); }

.hero-stats { display: flex; align-items: center; gap: 24px; }
.stat { display: flex; flex-direction: column; }
.stat-num { font-family: var(--font-serif); font-size: 1.5rem; color: var(--navy); line-height: 1; }
.stat-label { font-size: 0.68rem; color: var(--lgray); letter-spacing: 0.06em; margin-top: 4px; }
.stat-div { width: 1px; height: 32px; background: var(--rule); }

/* ── EIGEN VISUAL ─────────────────────────────────────── */
.hero-right {
  display: flex; align-items: center; justify-content: center;
  position: relative;
}
.eigen-visual {
  position: relative;
  width: clamp(280px, 40vw, 460px);
  aspect-ratio: 1;
  cursor: crosshair;
}
#eigenSvg {
  width: 100%; height: 100%;
  overflow: visible;
  filter: drop-shadow(0 8px 32px rgba(26,35,64,0.10));
}

/* SVG layers — gentle slow rotation via CSS on ID selectors */
#sqLav {
  transform-origin: 150px 150px;
  animation: rotateLavSVG 60s linear infinite;
}
#sqRose {
  transform-origin: 150px 150px;
  animation: rotateRoseSVG 80s linear infinite reverse;
}
/* Stripe drift inside rose square */
#sqRose g {
  animation: stripeFlow 14s linear infinite;
}
@keyframes stripeFlow {
  from { transform: translateX(0); }
  to   { transform: translateX(27px); }
}

/* No opacity:0 — always visible; entrance handled by JS */
#sqLav  { animation: rotateLavSVG  60s linear infinite; }
#sqRose { animation: rotateRoseSVG 80s linear infinite reverse; }
#sqGrid { }

@keyframes fadeLav {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes rotateLavSVG {
  from { transform: rotate(15deg); }
  to   { transform: rotate(375deg); }
}
@keyframes rotateRoseSVG {
  from { transform: rotate(-8deg) translate(10px,-10px); }
  to   { transform: rotate(-368deg) translate(10px,-10px); }
}

/* Tooltip */
.eigen-tooltip {
  position: absolute;
  background: rgba(26,35,64,0.88);
  color: #E4E2EE;
  padding: 6px 12px; border-radius: 2px;
  font-size: 0.7rem; letter-spacing: 0.08em;
  pointer-events: none;
  opacity: 0; transition: opacity 0.2s;
  display: flex; flex-direction: column;
  backdrop-filter: blur(4px);
  white-space: nowrap;
  left: 50%; top: 50%; transform: translate(-50%,-50%);
  border-left: 2px solid var(--rose);
}
.tt-label { color: var(--rose); font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.1em; }
.tt-value { font-family: var(--font-serif); font-size: 1rem; color: white; }
.eigen-visual:hover .eigen-tooltip { opacity: 1; }

/* ── ABOUT BAND ───────────────────────────────────────── */
#about {
  background: var(--navy);
  padding: 64px var(--pad-x);
}
.about-inner {
  max-width: var(--max-w); margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 64px; align-items: center;
}
.about-tagline {
  font-family: var(--font-serif); font-size: clamp(1.1rem, 2vw, 1.45rem);
  color: #C0C8D8; line-height: 1.65; font-weight: 300;
}
.about-tagline em { color: var(--lav); font-style: normal; }
.about-pillars { display: flex; flex-direction: column; gap: 24px; }
.pillar { display: flex; align-items: flex-start; gap: 16px; }
.pillar-num { font-family: var(--font-serif); color: var(--rose); font-size: 0.75rem; min-width: 20px; margin-top: 2px; }
.pillar-text { font-size: 0.9rem; color: #D8DCEC; line-height: 1.55; }

/* ── SERVICES ─────────────────────────────────────────── */
#services {
  padding: 100px var(--pad-x);
  max-width: var(--max-w); margin: 0 auto;
}
.section-header { margin-bottom: 56px; }
.section-header.light { }
.section-eyebrow {
  font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--rose); margin-bottom: 12px;
}
.section-title {
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  color: var(--navy);
}
.services-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 2px; background: var(--rule);
  align-items: start;
}
/* [5] Hover: card scales up, neighbours scale down slightly */
.service-card {
  background: var(--bg);
  padding: 40px 32px;
  transition: background 0.3s, transform 0.3s, box-shadow 0.3s, z-index 0s;
  position: relative;
  z-index: 1;
  transform-origin: center top;
}
.services-grid:hover .service-card { transform: scale(0.96); opacity: 0.85; }
.services-grid:hover .service-card:hover {
  transform: scale(1.04);
  opacity: 1;
  box-shadow: 0 12px 40px rgba(26,35,64,0.14);
  z-index: 10;
  background: var(--white);
}
.service-card.featured { background: var(--navy); }
.service-card.featured:hover { background: #1e2a4a !important; }
.card-num {
  font-family: var(--font-serif); font-size: 0.75rem;
  color: var(--rose); margin-bottom: 20px; letter-spacing: 0.08em;
}
.card-title {
  font-size: 1.4rem; color: var(--navy); margin-bottom: 10px;
}
.service-card.featured .card-title { color: var(--white); }
.card-sub {
  font-size: 0.78rem; color: var(--gray); margin-bottom: 24px; line-height: 1.6;
  border-bottom: 1px solid var(--rule); padding-bottom: 20px;
}
.service-card.featured .card-sub { color: #9098B0; border-color: #2E3A56; }
.card-list {
  list-style: none; margin-bottom: 28px;
  display: flex; flex-direction: column; gap: 10px;
}
.card-list li {
  font-size: 0.9rem; color: var(--dark);
  padding-left: 16px; position: relative; line-height: 1.6;
}
.card-list li::before {
  content: '—'; position: absolute; left: 0;
  color: var(--rose); font-size: 0.75rem; top: 2px;
}
/* [5] Bold text prominent */
.card-list li strong {
  font-weight: 500; color: var(--navy);
}
.service-card.featured .card-list li { color: #C0C8D8; }
.service-card.featured .card-list li strong { color: #E4E8F4; }
/* Tags now appear directly under title (card-tags-top) */
.card-tags-top {
  font-size: 0.82rem; font-weight: 500;
  color: var(--rose);
  letter-spacing: 0.01em;
  margin-bottom: 20px;
  margin-top: 6px;
  line-height: 1.65;
}
.service-card.featured .card-tags-top { color: #C8A098; }

/* Legacy .card-tags kept for fallback */
.card-tags {
  font-size: 0.7rem; color: var(--lgray); line-height: 1.7;
  border-top: 1px solid var(--rule); padding-top: 16px;
  letter-spacing: 0.02em;
}
.service-card.featured .card-tags { color: #7880A0; border-color: #2E3A56; }

/* ── MANDATES ─────────────────────────────────────────── */
#mandates {
  background: var(--navy);
  padding: 100px var(--pad-x);
}
#mandates .section-header { margin-bottom: 56px; }
#mandates .section-title { color: var(--white); }
#mandates .section-eyebrow { color: var(--rose); }

#mandates .section-header,
.mandates-grid, .lp-network {
  max-width: var(--max-w); margin-left: auto; margin-right: auto;
}

.mandates-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2px; background: #2A3354;
  margin-bottom: 48px;
}
.mandate-card {
  background: #1E2848;
  padding: 28px 24px;
  border-top: 2px solid transparent;
  transition: border-color 0.3s, background 0.3s;
}
.mandate-card:hover { background: #243060; border-color: var(--rose); }
.mandate-card.featured-mandate {
  grid-column: span 2;
  background: #252E54;
  border-top: 2px solid var(--rose);
}
.mandate-type {
  font-size: 0.72rem; color: var(--rose); letter-spacing: 0.06em;
  text-transform: uppercase; margin-bottom: 10px;
}
.mandate-size {
  font-family: var(--font-serif); font-size: 1.6rem;
  color: var(--white); margin-bottom: 12px; line-height: 1;
}
.mandate-desc {
  font-size: 0.75rem; color: #8090B0; line-height: 1.6;
}

.lp-network {
  border-top: 1px solid #2E3A56; padding-top: 40px;
}
.network-label {
  font-size: 0.78rem; color: var(--rose); letter-spacing: 0.1em;
  text-transform: uppercase; margin-bottom: 24px;
}
.network-cols { display: grid; grid-template-columns: repeat(4,1fr); gap: 32px; }
.nc-region { display: block; font-size: 1.05rem; color: #C0CADA; margin-bottom: 8px; font-weight: 400; }
.nc-types { font-size: 0.88rem; color: #7080A8; line-height: 1.7; }

/* ── TEAM ─────────────────────────────────────────────── */
#team {
  background: var(--navy);
  padding: 100px var(--pad-x);
}
.team-inner {
  max-width: var(--max-w); margin: 0 auto;
}
#team .section-eyebrow { color: var(--rose); }
#team .section-title { color: var(--white); margin-bottom: 64px; }

.team-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  background: #2A3354;
  align-items: start; /* cards size to content, name+title always at top */
}
.team-card {
  background: #1E2848;
  padding: 52px 44px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  transition: background 0.3s;
}
.team-card:hover { background: #253060; }
.team-info {
  display: flex;
  flex-direction: column;
}
.team-name {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  font-weight: 400;
  color: var(--white);
  line-height: 1.15;
  /* Fixed height locks Partner to same vertical position across all 3 cards */
  height: 4.2rem;
  overflow: hidden;
}
.team-title {
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--rose);
  font-weight: 400;
  margin-top: 14px;
}

/* ── CONTACT ──────────────────────────────────────────── */
#contact {
  padding: 100px var(--pad-x);
}
.contact-inner {
  max-width: var(--max-w); margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 80px; align-items: start;
}
.contact-title {
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  color: var(--navy); margin-bottom: 16px;
}
.contact-body {
  font-size: 0.88rem; color: var(--gray);
  line-height: 1.75; margin-bottom: 36px; max-width: 380px;
}
.contact-links { display: flex; flex-direction: column; gap: 20px; }
.contact-link {
  display: flex; flex-direction: column; gap: 2px;
  text-decoration: none;
  padding: 16px 0; border-top: 1px solid var(--rule);
  transition: border-color 0.2s;
}
.contact-link:hover { border-color: var(--rose); }
.cl-label { font-size: 0.65rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--rose); }
.cl-val { font-size: 0.9rem; color: var(--navy); }

/* ── FORM ─────────────────────────────────────────────── */
.inquiry-form {
  background: var(--card-bg);
  padding: 40px 36px;
  display: flex; flex-direction: column; gap: 16px;
}
.form-title {
  font-family: var(--font-serif); font-size: 1.3rem;
  color: var(--navy); margin-bottom: 8px;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.inquiry-form input,
.inquiry-form select,
.inquiry-form textarea {
  background: var(--bg); border: 1px solid var(--rule);
  padding: 11px 14px; font-size: 0.82rem; color: var(--dark);
  font-family: var(--font-sans); font-weight: 300;
  outline: none; border-radius: 1px; width: 100%;
  transition: border-color 0.2s;
}
.inquiry-form input:focus,
.inquiry-form select:focus,
.inquiry-form textarea:focus { border-color: var(--navy); }
.inquiry-form textarea { resize: vertical; }
.btn-submit {
  background: var(--navy); color: var(--white);
  border: none; padding: 14px; font-size: 0.82rem;
  letter-spacing: 0.08em; cursor: pointer;
  font-family: var(--font-sans); font-weight: 400;
  transition: background 0.2s;
}
.btn-submit:hover { background: #253060; }
.form-note { font-size: 0.68rem; color: var(--lgray); text-align: center; }

/* ── FOOTER ───────────────────────────────────────────── */
footer {
  background: var(--dark);
  padding: 40px var(--pad-x);
}
.footer-inner {
  max-width: var(--max-w); margin: 0 auto;
  display: flex; flex-direction: column; gap: 16px; align-items: center;
  text-align: center;
}
.footer-brand { display: flex; align-items: baseline; gap: 8px; }
.footer-logo { font-family: var(--font-serif); font-size: 1.2rem; color: #E4E2EE; }
.footer-tagline { font-size: 0.7rem; color: #6070A0; letter-spacing: 0.08em; }
.footer-conf { font-size: 0.68rem; color: #404860; max-width: 560px; line-height: 1.65; }
.footer-copy { font-size: 0.65rem; color: #404860; }

/* ── SCROLL REVEAL ────────────────────────────────────── */
.reveal {
  opacity: 0; transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ── RESPONSIVE ───────────────────────────────────────── */
@media (max-width: 900px) {
  #hero { grid-template-columns: 1fr; min-height: auto; padding-top: 120px; }
  .hero-right { order: -1; }
  .eigen-visual { width: 260px; }
  .about-inner { grid-template-columns: 1fr; }
  .services-grid { grid-template-columns: 1fr; }
  .mandates-grid { grid-template-columns: 1fr 1fr; }
  .mandate-card.featured-mandate { grid-column: span 2; }
  .network-cols { grid-template-columns: 1fr 1fr; gap: 20px; }
  .contact-inner { grid-template-columns: 1fr; gap: 48px; }
  .form-row { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .nav-links { display: none; }
  .mandates-grid { grid-template-columns: 1fr; }
  .mandate-card.featured-mandate { grid-column: span 1; }
  .network-cols { grid-template-columns: 1fr; }
}
