/* ============================================
   AVONBRIDGE CAPITAL — Design System
   Cream & Charcoal | Original Logo Colorway
   ============================================ */

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

:root {
  /* Palette — matched to original Avonbridge Capital logo */
  --cream:        #f1ede5;
  --cream-dark:   #e6e1d7;
  --warm-white:   #f7f4ee;
  --gold:         #92908b;
  --gold-light:   #b5b3ae;
  --gold-dark:    #7d7a74;
  --navy:         #31302d;
  --navy-light:   #4a4945;
  --navy-muted:   #5a5855;
  --charcoal:     #31302d;
  --text-primary: #31302d;
  --text-secondary:#5a5855;
  --text-light:   #92908b;
  --border:       #d8d4cb;
  --border-light: #e6e1d7;
  --success:      #2D8A56;
  --white:        #FFFFFF;

  /* Typography */
  --font-heading: 'Playfair Display', 'Georgia', serif;
  --font-body:    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono:    'SF Mono', 'Fira Code', monospace;

  /* Spacing */
  --section-y:    120px;
  --section-x:    24px;
  --max-width:    1200px;
  --max-narrow:   800px;
  --radius:       12px;
  --radius-sm:    8px;
  --radius-lg:    20px;

  /* Transitions */
  --ease:         cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --duration:     0.3s;
}

html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body {
  font-family: var(--font-body);
  color: var(--text-primary);
  background: var(--cream);
  line-height: 1.7;
  font-size: 16px;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

/* --- Typography Scale --- */
h1 { font-family: var(--font-heading); font-size: clamp(2.4rem, 5vw, 3.8rem); font-weight: 700; line-height: 1.15; letter-spacing: -0.01em; color: var(--navy); }
h2 { font-family: var(--font-heading); font-size: clamp(1.8rem, 3.5vw, 2.6rem); font-weight: 700; line-height: 1.2; letter-spacing: -0.01em; color: var(--navy); }
h3 { font-family: var(--font-heading); font-size: clamp(1.2rem, 2vw, 1.5rem); font-weight: 600; line-height: 1.3; color: var(--navy); }
h4 { font-family: var(--font-heading); font-size: 1.1rem; font-weight: 600; line-height: 1.4; color: var(--navy); }
p  { font-size: 1.05rem; line-height: 1.75; color: var(--text-secondary); }
.text-lg { font-size: 1.2rem; line-height: 1.7; }
.text-sm { font-size: 0.9rem; }
.text-xs { font-size: 0.8rem; }

/* --- Layout --- */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 var(--section-x); }
.container-narrow { max-width: var(--max-narrow); margin: 0 auto; padding: 0 var(--section-x); }
.section { padding: var(--section-y) 0; }
.section-sm { padding: 80px 0; }

/* --- Navigation --- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: rgba(241, 237, 229, 0.88);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-light);
  transition: all var(--duration) var(--ease);
}
.nav-inner {
  max-width: var(--max-width); margin: 0 auto;
  padding: 0 var(--section-x);
  display: flex; align-items: center; justify-content: space-between;
  height: 120px;
}
.nav-logo {
  display: flex; align-items: center; gap: 12px;
  margin-left: -18px;
}
.nav-logo-mark {
  background: var(--cream-dark); padding: 6px 14px;
  border-radius: 2px; display: flex; flex-direction: column;
  align-items: center; line-height: 1;
  border: 1px solid var(--border);
  height: 72px; justify-content: center;
}
.nav-logo-text {
  font-size: 26px; font-weight: 700; color: var(--navy);
  letter-spacing: 0.12em; text-transform: uppercase;
}
.nav-logo-sub {
  font-size: 13px; font-weight: 600; color: var(--navy);
  letter-spacing: 0.22em; text-transform: uppercase; margin-top: 4px;
}
.nav-links { display: flex; align-items: center; gap: 28px; }
/* --- 3-dot More Menu --- */
.nav-more {
  position: relative; display: flex; align-items: center;
}
.nav-more-btn {
  background: none; border: none; cursor: pointer; padding: 8px;
  display: flex; align-items: center; gap: 3px;
  border-radius: 6px; transition: background var(--duration) var(--ease);
}
.nav-more-btn:hover { background: rgba(49,48,45,0.06); }
.nav-more-dot {
  width: 4px; height: 4px; background: var(--text-secondary);
  border-radius: 50%;
}
.nav-more-btn:hover .nav-more-dot { background: var(--navy); }
.nav-dropdown {
  position: absolute; top: calc(100% + 8px); right: 0;
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 8px 0;
  min-width: 220px; box-shadow: 0 12px 40px rgba(0,0,0,0.1);
  opacity: 0; visibility: hidden;
  transform: translateY(-4px);
  transition: all 0.2s var(--ease);
  z-index: 100;
}
.nav-dropdown.open { opacity: 1; visibility: visible; transform: translateY(0); }
.nav-dropdown a {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 20px; font-size: 0.85rem; font-weight: 500;
  color: var(--text-secondary); transition: all 0.15s var(--ease);
}
.nav-dropdown a:hover { background: var(--cream); color: var(--navy); }
.nav-dropdown a.active { color: var(--navy); }
.nav-dropdown-divider { height: 1px; background: var(--border-light); margin: 6px 0; }
.nav-dropdown-label {
  padding: 6px 20px 4px; font-size: 0.65rem; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-light);
}
.nav-links a {
  font-size: 0.9rem; font-weight: 500; color: var(--text-secondary);
  transition: color var(--duration) var(--ease);
  position: relative;
}
.nav-links a:hover, .nav-links a.active { color: var(--navy); }
.nav-links a.active::after {
  content: ''; position: absolute; bottom: -4px; left: 0; right: 0;
  height: 2px; background: var(--gold); border-radius: 1px;
}
.nav-cta {
  background: var(--navy); color: var(--white) !important;
  padding: 10px 24px; border-radius: var(--radius-sm);
  font-size: 0.85rem !important; font-weight: 500;
  transition: all var(--duration) var(--ease);
}
.nav-cta:hover { background: var(--navy-light); transform: translateY(-1px); }

/* Mobile menu */
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.nav-toggle span {
  display: block; width: 22px; height: 2px; background: var(--navy);
  margin: 5px 0; transition: all var(--duration) var(--ease); border-radius: 2px;
}

/* --- Buttons --- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 32px; border-radius: var(--radius-sm);
  font-size: 0.95rem; font-weight: 500;
  transition: all var(--duration) var(--ease);
  cursor: pointer; border: none; text-decoration: none;
}
.btn-primary {
  background: var(--navy); color: var(--white);
}
.btn-primary:hover { background: var(--navy-light); transform: translateY(-2px); box-shadow: 0 8px 30px rgba(49,48,45,0.2); }
.btn-secondary {
  background: transparent; color: var(--navy);
  border: 1.5px solid var(--border);
}
.btn-secondary:hover { border-color: var(--navy); background: var(--white); }
.btn-gold {
  background: linear-gradient(135deg, var(--navy), var(--navy-light));
  color: var(--white);
}
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(49,48,45,0.25); }
.btn-sm { padding: 10px 20px; font-size: 0.85rem; }
.btn-lg { padding: 18px 40px; font-size: 1rem; }
.btn-icon { width: 20px; height: 20px; }

/* --- Cards --- */
.card {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 40px;
  transition: all var(--duration) var(--ease);
}
.card:hover {
  border-color: var(--border);
  box-shadow: 0 12px 40px rgba(0,0,0,0.06);
  transform: translateY(-4px);
}
.card-icon {
  width: 48px; height: 48px;
  background: linear-gradient(135deg, rgba(49,48,45,0.08), rgba(49,48,45,0.03));
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px;
}
.card-icon svg { width: 24px; height: 24px; color: var(--navy); }

/* --- Hero Sections --- */
.hero {
  padding: 208px 0 var(--section-y);
  position: relative; overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, var(--cream) 0%, var(--cream-dark) 50%, var(--cream) 100%);
}
.hero-bg::before {
  content: ''; position: absolute; top: -30%; right: -20%;
  width: 800px; height: 800px;
  background: radial-gradient(circle, rgba(146,144,139,0.1) 0%, transparent 70%);
  border-radius: 50%;
}
.hero-bg::after {
  content: ''; position: absolute; bottom: -20%; left: -10%;
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(49,48,45,0.05) 0%, transparent 70%);
  border-radius: 50%;
}
.hero .container { position: relative; z-index: 1; }
.hero-label {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 16px; background: rgba(49,48,45,0.06);
  border-radius: 100px; font-size: 0.8rem; font-weight: 500;
  color: var(--navy); margin-bottom: 28px;
  letter-spacing: 0.02em;
}
.hero-label-dot {
  width: 6px; height: 6px; background: var(--gold);
  border-radius: 50%;
}
.hero h1 { margin-bottom: 24px; max-width: 720px; }
.hero p { max-width: 560px; font-size: 1.15rem; margin-bottom: 40px; }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }

/* Page hero (smaller, for inner pages) */
.page-hero {
  padding: 188px 0 80px;
  background: linear-gradient(180deg, var(--cream) 0%, var(--cream-dark) 100%);
  position: relative;
}
.page-hero h1 { margin-bottom: 16px; }
.page-hero p { max-width: 600px; }

/* --- Feature Image Blocks --- */
.feature-img {
  width: 100%; border-radius: var(--radius-lg);
  aspect-ratio: 16/9; object-fit: cover;
  border: 1px solid var(--border-light);
}
.feature-img-tall {
  aspect-ratio: 4/5; object-fit: cover;
}

/* --- Grid System --- */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.grid-2-1 { display: grid; grid-template-columns: 2fr 1fr; gap: 48px; align-items: start; }
.grid-1-1 { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }

/* --- Dividers & Accents --- */
.divider { height: 1px; background: var(--border); margin: var(--section-y) 0; }
.gold-line { width: 48px; height: 3px; background: var(--navy); border-radius: 2px; margin-bottom: 24px; }
.section-label {
  font-size: 0.75rem; font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--gold-dark); margin-bottom: 16px;
}

/* --- Stats Row --- */
.stats-row {
  display: flex; gap: 48px; flex-wrap: wrap;
  padding: 40px 0; border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border); margin: 48px 0;
}
.stat { flex: 1; min-width: 140px; }
.stat-value { font-size: 2rem; font-weight: 700; color: var(--navy); letter-spacing: -0.02em; }
.stat-label { font-size: 0.85rem; color: var(--text-light); margin-top: 4px; }

/* --- Process Steps --- */
.steps { counter-reset: step; }
.step {
  display: flex; gap: 32px; align-items: flex-start;
  padding: 32px 0; border-bottom: 1px solid var(--border-light);
  counter-increment: step;
}
.step:last-child { border-bottom: none; }
.step-number {
  width: 48px; height: 48px; flex-shrink: 0;
  background: var(--navy); color: var(--gold);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 1.1rem;
}
.step-content h3 { margin-bottom: 8px; }
.step-content p { font-size: 0.95rem; }

/* --- Comparison Table --- */
.comparison-table {
  width: 100%;
  border-collapse: separate; border-spacing: 0;
  border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--border);
  background: var(--white);
}
.comparison-table th {
  background: var(--navy); color: var(--white);
  padding: 16px 24px; font-weight: 600; font-size: 0.9rem;
  text-align: left;
}
.comparison-table td {
  padding: 14px 24px; border-bottom: 1px solid var(--border-light);
  font-size: 0.9rem; color: var(--text-secondary);
}
.comparison-table tr:last-child td { border-bottom: none; }
.comparison-table tr:hover td { background: rgba(49,48,45,0.02); }
.check { color: var(--success); font-weight: 600; }

/* --- Blog / News Cards --- */
.news-card {
  background: var(--white); border: 1px solid var(--border-light);
  border-radius: var(--radius-lg); overflow: hidden;
  transition: all var(--duration) var(--ease);
}
.news-card:hover {
  box-shadow: 0 12px 40px rgba(0,0,0,0.06);
  transform: translateY(-4px);
}
.news-card-img {
  width: 100%; aspect-ratio: 16/10; object-fit: cover;
}
.news-card-body { padding: 28px; }
.news-card-tag {
  display: inline-block; padding: 4px 12px;
  background: rgba(49,48,45,0.06); border-radius: 100px;
  font-size: 0.75rem; font-weight: 500; color: var(--navy);
  margin-bottom: 12px;
}
.news-card-body h3 { font-size: 1.15rem; margin-bottom: 8px; }
.news-card-body p { font-size: 0.9rem; }
.news-card-meta {
  display: flex; align-items: center; gap: 12px;
  margin-top: 16px; font-size: 0.8rem; color: var(--text-light);
}

/* --- Form Styles --- */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block; font-size: 0.85rem; font-weight: 500;
  color: var(--text-primary); margin-bottom: 8px;
}
.form-input, .form-textarea, .form-select {
  width: 100%; padding: 14px 16px;
  background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font-body); font-size: 0.95rem;
  color: var(--text-primary);
  transition: border-color var(--duration) var(--ease);
}
.form-input:focus, .form-textarea:focus, .form-select:focus {
  outline: none; border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(49,48,45,0.08);
}
.form-textarea { min-height: 120px; resize: vertical; }

/* --- HNWI Gateway --- */
.gateway-overlay {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(49,48,45,0.95);
  backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
  opacity: 1; transition: opacity 0.5s var(--ease);
}
.gateway-overlay.hidden { opacity: 0; pointer-events: none; }
.gateway-card {
  background: var(--white); border-radius: var(--radius-lg);
  padding: 56px 48px; max-width: 560px; width: 90%;
  text-align: center;
  box-shadow: 0 40px 80px rgba(0,0,0,0.3);
}
.gateway-card h2 { margin-bottom: 16px; }
.gateway-card p { margin-bottom: 32px; }
.gateway-options { display: flex; flex-direction: column; gap: 12px; margin-bottom: 24px; }
.gateway-option {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 16px; background: var(--cream);
  border-radius: var(--radius-sm); text-align: left;
  cursor: pointer; border: 2px solid transparent;
  transition: all var(--duration) var(--ease);
}
.gateway-option:hover { border-color: var(--navy); }
.gateway-option.selected { border-color: var(--navy); background: rgba(49,48,45,0.04); }
.gateway-option input { margin-top: 3px; accent-color: var(--navy); }
.gateway-option label { font-size: 0.9rem; color: var(--text-secondary); cursor: pointer; }
.gateway-option label strong { display: block; color: var(--text-primary); margin-bottom: 2px; }
.gateway-legal { font-size: 0.75rem; color: var(--text-light); margin-top: 16px; line-height: 1.5; }

/* --- Footer --- */
.footer {
  background: var(--navy); color: rgba(255,255,255,0.7);
  padding: 80px 0 40px;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px; margin-bottom: 60px;
}
.footer-brand p { font-size: 0.9rem; margin-top: 16px; line-height: 1.6; max-width: 300px; }
.footer-logo { font-size: 1.15rem; font-weight: 600; color: var(--white); }
.footer h4 {
  font-size: 0.75rem; font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; color: rgba(255,255,255,0.4);
  margin-bottom: 20px;
}
.footer a {
  display: block; font-size: 0.9rem; margin-bottom: 12px;
  transition: color var(--duration) var(--ease);
}
.footer a:hover { color: var(--white); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 28px;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 0.8rem; color: rgba(255,255,255,0.35);
}
.footer-disclaimer {
  max-width: 800px; font-size: 0.75rem; line-height: 1.6;
  color: rgba(255,255,255,0.3); margin-top: 24px;
}

/* --- LinkedIn Embed Area --- */
.linkedin-feed {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 32px;
  min-height: 400px;
}
.linkedin-feed-header {
  display: flex; align-items: center; gap: 12px; margin-bottom: 24px;
  padding-bottom: 16px; border-bottom: 1px solid var(--border-light);
}
.linkedin-icon {
  width: 28px; height: 28px;
  background: #0A66C2; border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  .grid-2 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .grid-1-1 { grid-template-columns: 1fr; gap: 40px; }
  .grid-2-1 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  :root { --section-y: 80px; }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-toggle { display: block; }
  .nav-inner { height: 96px; }
  .nav-logo img { height: 76px !important; }
  .nav-links.open {
    display: flex; flex-direction: column;
    position: absolute; top: 96px; left: 0; right: 0;
    background: var(--cream); border-bottom: 1px solid var(--border);
    padding: 24px; gap: 20px;
  }
  .hero { padding: 168px 0 80px; }
  .page-hero { padding: 158px 0 60px; }
  .grid-3 { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: 1fr; }
  .stats-row { gap: 32px; }
  .card { padding: 28px; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
  .step { flex-direction: column; gap: 16px; }
  .gateway-card { padding: 36px 28px; }
}
