/* ============================================
   ENDENEX — JPM-Inspired Design System
   Salt Design Language · Amplitude · Open Sans · PT Mono
   ============================================ */

/* --- CSS Custom Properties --- */
:root {
  /* Colors — JPM-influenced infrastructure palette */
  --navy: #0A1628;
  --navy-light: #0F2039;
  --navy-mid: #162A45;
  --navy-deep: #060E1A;
  --teal: #007B8A;
  --teal-light: #009BAA;
  --teal-dark: #006570;
  --teal-muted: rgba(0, 123, 138, 0.12);
  --white: #FFFFFF;
  --cool-grey-50: #F4F5F7;
  --cool-grey-100: #E8EAED;
  --cool-grey-200: #D1D5DB;
  --cool-grey-300: #9CA3AF;
  --cool-grey-400: #6B7280;
  --cool-grey-500: #4B5563;
  --text-primary: #0A1628;
  --text-secondary: #4B5563;
  --text-muted: #6B7280;
  --text-on-dark: #E8EAED;
  --text-on-dark-muted: #9CA3AF;
  --border-light: #E8EAED;
  --border-dark: #1E3450;

  /* Typography — JPM Salt Design System */
  --font-display: 'Playfair Display', 'Georgia', serif;
  --font-sans: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'PT Mono', 'Courier New', monospace;

  /* Spacing scale */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;
  --space-5xl: 8rem;

  /* Layout */
  --max-width: 1200px;
  --max-width-narrow: 800px;
  --content-width: 780px;
  --header-height: 72px;

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 400ms ease;

  /* Color scheme */
  color-scheme: light;
}

/* --- Reset & Base --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-primary);
  background: var(--white);
  overflow-x: hidden;
}

img, svg {
  display: block;
  max-width: 100%;
}

a {
  color: var(--teal);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--teal-dark);
}

/* --- Typography — JPM Amplitude-inspired hierarchy --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.08;
}

h2 {
  font-size: clamp(1.625rem, 3.5vw, 2.5rem);
  font-weight: 700;
}

h3 {
  font-size: clamp(1.25rem, 2vw, 1.5rem);
  font-weight: 700;
}

h4 {
  font-size: 1.125rem;
  font-weight: 700;
  font-family: var(--font-sans);
}

p {
  margin-bottom: var(--space-md);
  color: var(--text-secondary);
  line-height: 1.75;
}

p:last-child {
  margin-bottom: 0;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: var(--space-md);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.eyebrow::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 1px;
  background: var(--teal);
}

.subtitle {
  font-size: 1.125rem;
  line-height: 1.65;
  color: var(--text-secondary);
  max-width: var(--content-width);
}

/* --- Layout --- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-xl);
}

.container--narrow {
  max-width: var(--max-width-narrow);
}

/* Consistent body text width across ALL pages */
.body-content {
  max-width: var(--content-width);
}

.section {
  padding: var(--space-5xl) 0;
  position: relative;
}

.section--grey {
  background: var(--cool-grey-50);
}

.section--navy {
  background: var(--navy);
  color: var(--text-on-dark);
  position: relative;
  overflow: hidden;
}

.section--navy::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 50%;
  height: 100%;
  background: radial-gradient(ellipse at 100% 0%, rgba(0, 123, 138, 0.08) 0%, transparent 60%);
  pointer-events: none;
}

.section--navy h1,
.section--navy h2,
.section--navy h3,
.section--navy h4 {
  color: var(--white);
}

.section--navy p {
  color: var(--text-on-dark-muted);
}

.section--navy .eyebrow {
  color: var(--teal-light);
}

.section--navy .eyebrow::before {
  background: var(--teal-light);
}

/* Dark hero variant */
.section--dark-hero {
  background: var(--navy);
  color: var(--text-on-dark);
  position: relative;
  overflow: hidden;
}

.section--dark-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 80%, rgba(0, 123, 138, 0.1) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(0, 123, 138, 0.06) 0%, transparent 50%);
  pointer-events: none;
}

.section--dark-hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--teal), transparent);
  opacity: 0.3;
}

/* Grid */
.grid {
  display: grid;
  gap: var(--space-2xl);
}

.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 768px) {
  .grid--2, .grid--3, .grid--4 {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
}

/* --- Header / Navigation --- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--white);
  border-bottom: 1px solid var(--border-light);
  height: var(--header-height);
  transition: box-shadow var(--transition-base);
}

.site-header.scrolled {
  box-shadow: 0 2px 20px rgba(10, 22, 40, 0.08);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-xl);
}

.logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.logo svg {
  height: 24px;
  width: auto;
}

/* Desktop Nav */
.main-nav {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  list-style: none;
}

.main-nav > li {
  position: relative;
}

.main-nav > li > a,
.nav-trigger {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 0.5rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--text-primary);
  text-decoration: none;
  border-radius: 0;
  transition: color var(--transition-fast);
  cursor: pointer;
  background: none;
  border: none;
  font-family: var(--font-sans);
  white-space: nowrap;
}

.main-nav > li > a:hover,
.nav-trigger:hover {
  color: var(--teal);
}

.nav-trigger .chevron {
  width: 12px;
  height: 12px;
  transition: transform var(--transition-fast);
}

.nav-item:hover .chevron,
.nav-item.active .chevron {
  transform: rotate(180deg);
}

/* Dropdown */
.dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: 2px;
  box-shadow: 0 16px 48px rgba(10, 22, 40, 0.12);
  padding: var(--space-sm);
  min-width: 340px;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition-fast), visibility var(--transition-fast), transform var(--transition-fast);
  transform: translateX(-50%) translateY(4px);
}

.dropdown--two-col {
  min-width: 660px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 var(--space-xs);
}

.nav-item:hover .dropdown,
.nav-item.active .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.dropdown-item {
  display: block;
  padding: 0.875rem 1rem;
  border-radius: 2px;
  transition: background var(--transition-fast);
  text-decoration: none;
  border-left: 2px solid transparent;
}

.dropdown-item:hover {
  background: var(--cool-grey-50);
  border-left-color: var(--teal);
}

.dropdown-item-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text-primary);
  display: block;
  margin-bottom: 3px;
  font-family: var(--font-sans);
}

.dropdown-item-desc {
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.45;
  display: block;
}

/* Mobile Nav Toggle */
.mobile-toggle {
  display: none;
  background: none;
  border: none;
  padding: 0.5rem;
  cursor: pointer;
  color: var(--text-primary);
}

.mobile-toggle svg {
  width: 24px;
  height: 24px;
}

/* Mobile Nav */
.mobile-nav {
  display: none;
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--white);
  z-index: 999;
  overflow-y: auto;
  padding: var(--space-lg);
}

.mobile-nav.open {
  display: block;
}

.mobile-nav-section {
  border-bottom: 1px solid var(--border-light);
  padding: var(--space-md) 0;
}

.mobile-nav-section:last-child {
  border-bottom: none;
}

.mobile-nav-title {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: var(--space-sm) 0;
  font-family: var(--font-mono);
}

.mobile-nav-link {
  display: block;
  padding: 0.625rem 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  text-decoration: none;
}

.mobile-nav-link:hover {
  color: var(--teal);
}

@media (max-width: 900px) {
  .main-nav {
    display: none;
  }
  .mobile-toggle {
    display: block;
  }
}

/* --- Hero Sections --- */
.hero {
  padding-top: calc(var(--header-height) + var(--space-5xl));
  padding-bottom: var(--space-5xl);
}

/* Home hero — dark, cinematic */
.hero--home {
  background: var(--navy);
  color: var(--text-on-dark);
  position: relative;
  overflow: hidden;
  min-height: calc(100vh - var(--header-height));
  display: flex;
  align-items: center;
  padding-top: var(--header-height);
  padding-bottom: 0;
}

.hero--home::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 70%, rgba(0, 123, 138, 0.12) 0%, transparent 50%),
    radial-gradient(ellipse at 70% 30%, rgba(0, 123, 138, 0.06) 0%, transparent 50%);
  pointer-events: none;
}

/* Geometric grid pattern overlay */
.hero--home::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 123, 138, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 123, 138, 0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
}

.hero--home .container {
  position: relative;
  z-index: 1;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-4xl);
  align-items: center;
  min-height: calc(100vh - var(--header-height));
  padding: var(--space-4xl) 0;
}

.hero--home h1 {
  color: var(--white);
  margin-bottom: var(--space-lg);
}

.hero--home .hero__subtitle {
  color: var(--text-on-dark-muted);
  font-size: 1.0625rem;
  line-height: 1.75;
  margin-bottom: var(--space-2xl);
  max-width: 520px;
}

.hero--home .eyebrow {
  color: var(--teal-light);
}

.hero--home .eyebrow::before {
  background: var(--teal-light);
}

.hero__visual {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.hero__meta {
  margin-top: var(--space-2xl);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border-dark);
}

.hero__meta-label {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
  margin-bottom: var(--space-xs);
}

.hero__meta-items {
  display: flex;
  gap: var(--space-lg);
  flex-wrap: wrap;
}

.hero__meta-item {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--white);
  font-family: var(--font-sans);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.hero__meta-item::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--teal);
  flex-shrink: 0;
}

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    min-height: auto;
    padding: var(--space-3xl) 0;
  }
  .hero__visual {
    order: -1;
  }
}

/* Inner page hero — dark full-width band */
.hero--inner {
  background: var(--navy);
  color: var(--text-on-dark);
  padding-top: calc(var(--header-height) + var(--space-4xl));
  padding-bottom: var(--space-3xl);
  position: relative;
  overflow: hidden;
}

.hero--inner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 80% 50%, rgba(0, 123, 138, 0.08) 0%, transparent 50%);
  pointer-events: none;
}

.hero--inner::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--teal), transparent);
  opacity: 0.3;
}

.hero--inner .hero__content {
  position: relative;
  z-index: 1;
  max-width: var(--content-width);
}

.hero--inner h1 {
  color: var(--white);
  margin-bottom: var(--space-md);
}

.hero--inner .hero__subtitle {
  color: var(--text-on-dark-muted);
  max-width: var(--content-width);
}

.hero--inner .eyebrow {
  color: var(--teal-light);
}

.hero--inner .eyebrow::before {
  background: var(--teal-light);
}

/* --- Pictogram Icons (inline SVG-style, premium) --- */
.pictogram {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-lg);
  color: var(--teal);
  position: relative;
}

.pictogram::before {
  content: '';
  position: absolute;
  inset: -6px;
  background: var(--teal-muted);
  opacity: 0;
  transition: opacity var(--transition-base);
}

.card:hover .pictogram::before,
.body-content:hover .pictogram::before {
  opacity: 1;
}

.pictogram svg {
  width: 56px;
  height: 56px;
  position: relative;
  z-index: 1;
}

.pictogram--sm {
  width: 36px;
  height: 36px;
}

.pictogram--sm svg {
  width: 36px;
  height: 36px;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1;
  border-radius: 0;
  border: none;
  cursor: pointer;
  transition: all var(--transition-base);
  text-decoration: none;
  white-space: nowrap;
}

.btn--primary {
  background: var(--teal);
  color: var(--white);
}

.btn--primary:hover {
  background: var(--teal-dark);
  color: var(--white);
}

.btn--outline {
  background: transparent;
  color: var(--text-primary);
  border: 2px solid var(--text-primary);
}

.btn--outline:hover {
  border-color: var(--teal);
  color: var(--teal);
}

.btn--outline-light {
  background: transparent;
  color: var(--white);
  border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn--outline-light:hover {
  border-color: var(--teal-light);
  color: var(--teal-light);
}

.btn--navy {
  background: var(--navy);
  color: var(--white);
}

.btn--navy:hover {
  background: var(--navy-light);
  color: var(--white);
}

.btn--ghost {
  background: transparent;
  color: var(--teal);
  padding: 0;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 600;
  font-size: 0.9375rem;
}

.btn--ghost:hover {
  color: var(--teal-dark);
}

.btn svg {
  width: 16px;
  height: 16px;
}

/* --- Cards --- */
.card {
  background: var(--white);
  border: 1px solid var(--border-light);
  padding: var(--space-2xl) var(--space-xl);
  transition: box-shadow var(--transition-base), transform var(--transition-base);
  position: relative;
}

.card:hover {
  box-shadow: 0 8px 32px rgba(10, 22, 40, 0.08);
  transform: translateY(-2px);
}

.card__eyebrow {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: var(--space-sm);
  font-weight: 400;
}

.card__title {
  font-size: 1.375rem;
  font-weight: 700;
  margin-bottom: var(--space-sm);
  color: var(--text-primary);
  font-family: var(--font-display);
}

.card__text {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

.card__subtitle {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: var(--space-md);
  line-height: 1.5;
}

.card__note {
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-top: var(--space-md);
  padding-top: var(--space-md);
  border-top: 1px solid var(--border-light);
}

/* Index card variant — sharp top teal bar */
.card--index {
  border-top: 4px solid var(--teal);
  padding-top: var(--space-2xl);
}

.card--index:hover {
  border-top-color: var(--teal-light);
}

/* Feature card with left teal accent */
.card--feature {
  border-left: 3px solid var(--teal);
  background: var(--white);
}

/* --- Section Headers --- */
.section-header {
  margin-bottom: var(--space-3xl);
  max-width: var(--content-width);
}

.section-header--center {
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

.section-header h2 {
  margin-bottom: var(--space-md);
}

/* Teal accent bar under h2 in section-header */
.section-header h2::after {
  content: '';
  display: block;
  width: 40px;
  height: 3px;
  background: var(--teal);
  margin-top: var(--space-md);
}

.section-header--center h2::after {
  margin-left: auto;
  margin-right: auto;
}

/* --- Index Series spacing: body-content to cards --- */
#index-series .body-content {
  margin-bottom: var(--space-3xl);
}

/* --- Insights / Article List --- */
.insight-item {
  display: block;
  padding: var(--space-xl) 0;
  padding-left: var(--space-lg);
  border-bottom: 1px solid var(--border-light);
  text-decoration: none;
  transition: all var(--transition-fast);
  position: relative;
}

.insight-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 0;
  background: var(--teal);
  transition: height var(--transition-base);
}

.insight-item:hover::before {
  height: 60%;
}

.insight-item:first-child {
  border-top: 1px solid var(--border-light);
}

.insight-item:hover {
  background: var(--cool-grey-50);
}

.insight-meta {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-xs);
}

.insight-date {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.insight-tag {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--teal);
  font-weight: 400;
  background: var(--teal-muted);
  padding: 2px 8px;
}

.insight-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-xs);
  font-family: var(--font-display);
}

.insight-excerpt {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* --- Forms --- */
.form-group {
  margin-bottom: var(--space-lg);
}

.form-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
  text-transform: uppercase;
  font-family: var(--font-sans);
}

.form-input {
  width: 100%;
  padding: 0.875rem 1rem;
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  color: var(--text-primary);
  background: var(--white);
  border: 1px solid var(--cool-grey-200);
  border-radius: 0;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  outline: none;
}

.form-input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(0, 123, 138, 0.1);
}

.form-input::placeholder {
  color: var(--cool-grey-300);
}

.form-inline {
  display: flex;
  gap: var(--space-sm);
}

.form-inline .form-input {
  flex: 1;
}

@media (max-width: 500px) {
  .form-inline {
    flex-direction: column;
  }
}

.form-note {
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin-top: var(--space-sm);
}

/* --- Footer --- */
.site-footer {
  background: var(--navy);
  color: var(--text-on-dark);
  padding: var(--space-4xl) 0 var(--space-2xl);
  position: relative;
}

.site-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--teal), transparent);
  opacity: 0.5;
}

/* Sitemap columns */
.footer-nav {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-2xl);
  padding-bottom: var(--space-3xl);
  border-bottom: 1px solid var(--border-dark);
  margin-bottom: var(--space-xl);
}

.footer-nav__heading {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--teal-light);
  margin-bottom: var(--space-md);
}

.footer-nav__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.footer-nav__list a {
  font-size: 0.875rem;
  color: var(--text-on-dark-muted);
  text-decoration: none;
  transition: color var(--transition-fast);
  line-height: 1.5;
}

.footer-nav__list a:hover {
  color: var(--white);
}

/* Bottom bar */
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-lg);
}

.footer-logo svg {
  height: 18px;
  width: auto;
  display: block;
}

.footer-copy {
  font-size: 0.6875rem;
  color: var(--text-on-dark-muted);
  font-family: var(--font-mono);
  letter-spacing: 0.02em;
}

.footer-social {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.footer-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  color: var(--text-on-dark-muted);
  transition: color var(--transition-fast);
}

.footer-social a:hover {
  color: var(--teal-light);
}

.footer-social svg {
  width: 20px;
  height: 20px;
}

@media (max-width: 768px) {
  .footer-nav {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
  }
}

@media (max-width: 600px) {
  .footer-nav {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-lg);
  }
  .footer-bottom {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: var(--space-md);
  }
  .footer-copy {
    text-align: center;
  }
}

/* --- Modal Popup (Get Notified / Register) --- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(6, 14, 26, 0.6);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition-base), visibility var(--transition-base);
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: var(--white);
  width: 100%;
  max-width: 440px;
  padding: var(--space-3xl);
  position: relative;
  box-shadow: 0 32px 80px rgba(6, 14, 26, 0.2);
  transform: translateY(16px);
  transition: transform var(--transition-base);
}

.modal-overlay.active .modal {
  transform: translateY(0);
}

.modal-close {
  position: absolute;
  top: var(--space-md);
  right: var(--space-md);
  background: none;
  border: none;
  padding: 8px;
  cursor: pointer;
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.modal-close:hover {
  color: var(--text-primary);
}

.modal-close svg {
  width: 20px;
  height: 20px;
}

.modal h3 {
  font-family: var(--font-display);
  font-size: 1.375rem;
  margin-bottom: var(--space-sm);
}

.modal p {
  font-size: 0.9375rem;
  margin-bottom: var(--space-xl);
}

.modal .form-group {
  margin-bottom: var(--space-md);
}

.modal .btn {
  width: 100%;
  justify-content: center;
  margin-top: var(--space-sm);
}

/* --- Long-form Content (Policy, IOSCO, Methodology) --- */
.long-content {
  max-width: var(--content-width);
}

.long-content h2 {
  margin-top: var(--space-3xl);
  margin-bottom: var(--space-lg);
  padding-top: var(--space-xl);
  position: relative;
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
}

.long-content h2::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background: var(--teal);
}

.long-content h2:first-of-type {
  padding-top: 0;
  margin-top: 0;
}

.long-content h2:first-of-type::before {
  display: none;
}

.long-content h3 {
  margin-top: var(--space-xl);
  margin-bottom: var(--space-md);
  font-size: 1.125rem;
}

.long-content p {
  line-height: 1.8;
}

.long-content ul, .long-content ol {
  padding-left: 1.5rem;
  margin-bottom: var(--space-lg);
}

.long-content li {
  margin-bottom: var(--space-sm);
  color: var(--text-secondary);
  line-height: 1.75;
}

.long-content strong {
  color: var(--text-primary);
  font-weight: 700;
}

/* --- Abstract Geometric Visual --- */
.abstract-visual {
  width: 100%;
  aspect-ratio: 4/3;
  overflow: hidden;
  position: relative;
}

.abstract-visual svg {
  width: 100%;
  height: 100%;
}

/* --- User Types Grid --- */
.user-type {
  padding: var(--space-xl);
  padding-left: calc(var(--space-xl) + 3px);
  border-left: 3px solid var(--cool-grey-200);
  transition: border-color var(--transition-base);
  position: relative;
}

.user-type:hover {
  border-left-color: var(--teal);
}

.user-type__title {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
  font-family: var(--font-display);
}

.user-type__text {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* --- Divider --- */
.divider {
  width: 40px;
  height: 3px;
  background: var(--teal);
  margin: var(--space-xl) 0;
}

/* --- Advisory service blocks --- */
.service-block {
  padding: var(--space-3xl) 0;
  position: relative;
}

.service-block + .service-block {
  border-top: 1px solid var(--border-light);
}

.service-block h2 {
  margin-bottom: var(--space-lg);
}

.service-block p {
  max-width: var(--content-width);
}

/* Alternating background */
.service-block:nth-child(even) {
  background: var(--cool-grey-50);
}

/* --- Stat / Metric Blocks --- */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-xl);
}

.stat-item {
  text-align: center;
  padding: var(--space-xl);
}

.stat-value {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--teal);
  line-height: 1;
  margin-bottom: var(--space-sm);
}

.stat-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-family: var(--font-mono);
}

@media (max-width: 600px) {
  .stat-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* --- Leader Card --- */
.leader-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: var(--space-xl);
  align-items: start;
}

.leader-avatar {
  width: 120px;
  height: 120px;
  border-radius: 0;
  overflow: hidden;
  flex-shrink: 0;
  position: relative;
  background: var(--navy);
}

.leader-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.leader-name {
  font-size: 1.375rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
  font-family: var(--font-display);
}

.leader-role {
  font-size: 0.8125rem;
  color: var(--teal);
  margin-bottom: var(--space-md);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-family: var(--font-sans);
}

.leader-bio {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.75;
}

@media (max-width: 500px) {
  .leader-card {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .leader-avatar {
    margin: 0 auto;
  }
}

/* --- About Page Grid with Visual --- */
.about-company-grid {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: var(--space-2xl);
  align-items: start;
}

.about-visual {
  position: sticky;
  top: calc(var(--header-height) + var(--space-xl));
}

.about-visual svg {
  width: 100%;
  height: auto;
  opacity: 0.85;
}

@media (max-width: 900px) {
  .about-company-grid {
    grid-template-columns: 1fr;
  }
  .about-visual {
    display: none;
  }
}

/* --- Advisory Service Grid --- */
.advisory-service-grid {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: var(--space-2xl);
  align-items: start;
}

.advisory-service-grid--reverse {
  grid-template-columns: 400px 1fr;
}

.advisory-service-grid--reverse > :first-child {
  order: 2;
}

.advisory-service-grid--reverse > :last-child {
  order: 1;
}

.advisory-visual {
  position: sticky;
  top: calc(var(--header-height) + var(--space-xl));
}

.advisory-visual svg {
  width: 100%;
  height: auto;
  opacity: 0.85;
}

@media (max-width: 768px) {
  .advisory-service-grid,
  .advisory-service-grid--reverse {
    grid-template-columns: 1fr;
  }
  .advisory-service-grid--reverse > :first-child {
    order: 1;
  }
  .advisory-service-grid--reverse > :last-child {
    order: 2;
  }
  .advisory-visual {
    display: none;
  }
}

/* --- Contact Info Row (side-by-side) --- */
.contact-info-row {
  display: flex;
  gap: var(--space-2xl);
  align-items: flex-start;
}

.contact-info-row h4 {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--teal);
  margin-bottom: var(--space-xs);
  font-family: var(--font-sans);
}

.contact-info-row p {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

@media (max-width: 500px) {
  .contact-info-row {
    flex-direction: column;
    gap: var(--space-lg);
  }
}

/* --- Section Divider --- */
.section-divider {
  width: 100%;
  height: 1px;
  overflow: hidden;
}

.section-divider svg {
  width: 100%;
  height: 2px;
  display: block;
}

/* --- Google Map embed --- */
.map-embed {
  width: 100%;
  height: 360px;
  overflow: hidden;
  border: 1px solid var(--border-light);
}

.map-embed iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* --- Geometric decorative elements --- */

/* Corner bracket decoration */
.deco-bracket {
  position: relative;
}

.deco-bracket::before,
.deco-bracket::after {
  content: '';
  position: absolute;
  width: 24px;
  height: 24px;
  pointer-events: none;
}

.deco-bracket::before {
  top: -1px;
  left: -1px;
  border-top: 2px solid var(--teal);
  border-left: 2px solid var(--teal);
}

.deco-bracket::after {
  bottom: -1px;
  right: -1px;
  border-bottom: 2px solid var(--teal);
  border-right: 2px solid var(--teal);
}

/* Teal accent line */
.accent-line {
  width: 40px;
  height: 3px;
  background: var(--teal);
  margin-bottom: var(--space-lg);
}

/* --- Scroll offset for anchor links --- */
[id] {
  scroll-margin-top: calc(var(--header-height) + var(--space-xl));
}

/* --- Utility --- */
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.mt-0 { margin-top: 0; }
.mt-lg { margin-top: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }
.mt-2xl { margin-top: var(--space-2xl); }
.mb-0 { margin-bottom: 0; }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }
.mb-xl { margin-bottom: var(--space-xl); }
.mb-2xl { margin-bottom: var(--space-2xl); }
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* --- Section graphic patterns --- */

/* Dot grid background pattern */
.bg-dots {
  position: relative;
}

.bg-dots::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, var(--cool-grey-200) 1px, transparent 1px);
  background-size: 24px 24px;
  opacity: 0.4;
  pointer-events: none;
}

.bg-dots > * {
  position: relative;
  z-index: 1;
}

/* Diagonal lines pattern */
.bg-lines::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    -45deg,
    transparent,
    transparent 20px,
    rgba(0, 123, 138, 0.03) 20px,
    rgba(0, 123, 138, 0.03) 21px
  );
  pointer-events: none;
}

/* Section separator — teal gradient line */
.section-sep {
  height: 1px;
  background: linear-gradient(90deg, transparent 5%, var(--teal) 50%, transparent 95%);
  opacity: 0.2;
}

/* --- Responsive adjustments --- */
@media (max-width: 768px) {
  .section {
    padding: var(--space-3xl) 0;
  }

  .hero {
    padding-top: calc(var(--header-height) + var(--space-3xl));
    padding-bottom: var(--space-3xl);
  }

  h1 {
    font-size: clamp(1.75rem, 5vw, 2.5rem);
  }

  h2 {
    font-size: clamp(1.375rem, 3.5vw, 2rem);
  }
}

/* ============================================
   PUBLICATION PAGE
   ============================================ */

/* --- Publication Header --- */
.pub-header {
  padding-top: calc(var(--header-height) + var(--space-3xl));
  padding-bottom: var(--space-2xl);
  border-bottom: 1px solid var(--border-light);
}

.pub-header__inner {
  max-width: var(--content-width);
}

.pub-back {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--teal);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-family: var(--font-sans);
  margin-bottom: var(--space-xl);
}

.pub-back:hover {
  color: var(--teal-dark);
}

.pub-meta {
  display: flex;
  align-items: center;
  gap: 0.5em;
  font-size: 0.8125rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
  margin-bottom: var(--space-md);
}

.pub-meta__tag {
  font-weight: 600;
  color: var(--teal);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.pub-meta__sep {
  color: var(--cool-grey-300);
}

.pub-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.15;
  margin-bottom: var(--space-md);
  letter-spacing: -0.01em;
}

.pub-subtitle {
  font-size: 1.1875rem;
  color: var(--text-secondary);
  line-height: 1.5;
  max-width: 600px;
  margin-bottom: var(--space-xl);
}

/* --- Actions Bar (Download + Share) --- */
.pub-actions {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
  flex-wrap: wrap;
}

.pub-download {
  gap: 0.5em;
}

.pub-download svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.pub-share {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.pub-share__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border-light);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.pub-share__btn:hover {
  color: var(--teal);
  border-color: var(--teal);
}

.pub-share__btn svg {
  width: 16px;
  height: 16px;
}

/* --- Publication Body --- */
.pub-body {
  padding: var(--space-3xl) 0 var(--space-4xl);
}

.pub-content {
  max-width: var(--content-width);
}

/* Article typography — optimised for long-form reading */
.pub-content p {
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.85;
  color: var(--text-secondary);
  margin-bottom: 1.5em;
}

.pub-content .pub-lede {
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1.7;
  margin-bottom: 1.75em;
}

.pub-content h2 {
  font-family: var(--font-display);
  font-size: 1.625rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-top: 3em;
  margin-bottom: 1em;
  padding-top: 1.5em;
  border-top: 1px solid var(--border-light);
  letter-spacing: -0.01em;
}

.pub-content h2:first-of-type {
  margin-top: 2em;
}

/* --- Disclaimer Section --- */
.pub-disclaimer {
  margin-top: 3em;
  padding-top: 2em;
  border-top: 2px solid var(--border-light);
}

.pub-disclaimer h3 {
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-primary);
  margin-bottom: 0.5em;
  margin-top: 1.5em;
}

.pub-disclaimer h3:first-child {
  margin-top: 0;
}

.pub-content .pub-disclaimer p {
  font-size: 0.8125rem;
  line-height: 1.65;
  color: var(--text-muted);
  margin-bottom: 1em;
}

.pub-content .pub-disclaimer__copy {
  margin-top: 1.5em;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--cool-grey-400);
}

/* --- Responsive --- */
@media (max-width: 600px) {
  .pub-header {
    padding-top: calc(var(--header-height) + var(--space-xl));
    padding-bottom: var(--space-xl);
  }

  .pub-actions {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-md);
  }

  .pub-content p {
    font-size: 1rem;
  }

  .pub-content h2 {
    font-size: 1.375rem;
  }
}

/* ============================================================
   MOTION PREFERENCES
   ============================================================ */

/* Smooth scrolling only for users who haven't opted out */
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

/* Strip motion for users who prefer reduced movement */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  /* Keep the insight bar visible at rest so hover still gives feedback */
  .insight-item::before {
    height: 100%;
    opacity: 0;
    transition: none !important;
  }
  .insight-item:hover::before {
    opacity: 1;
  }
}

/* ============================================================
   KEYBOARD FOCUS STYLES
   ============================================================ */

/* Global ring — teal brand colour, clear offset */
:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 3px;
  border-radius: 2px;
}

/* Suppress the ring on mouse/touch interactions */
:focus:not(:focus-visible) {
  outline: none;
}

/* Navigation items — slightly tighter offset inside the header */
.nav-link:focus-visible,
.nav-trigger:focus-visible,
.dropdown-item:focus-visible,
.mobile-nav-link:focus-visible {
  outline: 2px solid var(--teal-light);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Buttons — ring + subtle glow so it reads against both light and dark surfaces */
.btn:focus-visible {
  outline: 2px solid var(--teal-light);
  outline-offset: 3px;
  box-shadow: 0 0 0 4px var(--teal-muted);
}

/* Cards & article rows — hug the container edge */
.card:focus-visible,
.insight-item:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 0;
  border-radius: 0;
}

/* Form inputs already use a border-color + box-shadow focus cue;
   leave that mechanism intact and only suppress the duplicate ring */
.form-input:focus-visible {
  outline: none;
}

/* ============================================================
   SKIP NAVIGATION
   ============================================================ */

/* Visually hidden until focused; becomes visible for keyboard users.
   NOTE: add <a class="skip-to-content" href="#main">Skip to content</a>
   as the very first element inside <body> on each page. */
.skip-to-content {
  position: absolute;
  top: -999px;
  left: 1rem;
  z-index: 9999;
  padding: 0.75rem 1.25rem;
  background: var(--navy);
  color: var(--white);
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 0 0 4px 4px;
  transition: top var(--transition-fast);
}

.skip-to-content:focus {
  top: 0;
  outline: 2px solid var(--teal-light);
  outline-offset: 3px;
}
