/* ============================================
   CBI, LLC. — Design System
   Ink Navy / Gold / Paper — Executive Search
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Source+Serif+4:opsz,wght@8..60,400;8..60,600;8..60,700&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --ink-navy: #0a1830;
  --deep-navy: #050d1a;
  --gold-start: #a67c1e;
  --gold-end: #e8c468;
  --paper: #f7f6f2;
  --paper-dim: #efece4;
  --steel: #64748b;
  --cobalt: #2f6fed;
  --hairline: #e2ded4;
  --max-width: 1120px;
  --serif: 'Source Serif 4', Georgia, 'Times New Roman', serif;
  --sans: 'Inter', Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink-navy);
  background: var(--paper);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: var(--cobalt); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: var(--max-width); margin: 0 auto; padding: 0 32px; }

/* ---------- Header ---------- */

header.site-header { padding: 28px 0 20px; border-bottom: 1px solid var(--hairline); }

header.site-header .header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 16px;
}

.brand-block a.brand-link { display: inline-block; text-decoration: none; }
.brand-block img.logo { height: 46px; width: auto; display: block; }
.brand-block .site-url { font-family: var(--sans); font-size: 13px; color: var(--steel); letter-spacing: 0.3px; margin-top: 6px; }

nav.main-nav { display: flex; flex-wrap: wrap; }
nav.main-nav a {
  color: var(--ink-navy);
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  padding-bottom: 4px;
  border-bottom: 2px solid transparent;
  margin-left: 28px;
}
nav.main-nav a:first-child { margin-left: 0; }
nav.main-nav a:hover, nav.main-nav a.active { border-bottom: 2px solid var(--gold-start); text-decoration: none; }

/* ---------- Hero ---------- */

.hero { position: relative; padding: 90px 0 70px; overflow: hidden; }

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--hairline) 1px, transparent 1px),
    linear-gradient(90deg, var(--hairline) 1px, transparent 1px);
  background-size: 64px 64px;
  opacity: 0.35;
  mask-image: linear-gradient(to bottom, black, transparent 85%);
  -webkit-mask-image: linear-gradient(to bottom, black, transparent 85%);
  pointer-events: none;
}

.hero .wrap { position: relative; }

.hero.photo-hero {
  background-image:
    linear-gradient(rgba(5,13,26,0.72), rgba(5,13,26,0.82)),
    url('https://images.unsplash.com/photo-1535732759880-bbd5c7265e3f?fm=jpg&q=80&w=2400&auto=format&fit=crop&ixlib=rb-4.1.0');
  background-size: cover;
  background-position: center;
  color: #fff;
}
.hero.photo-hero::before { display: none; }
.hero.photo-hero h1 { color: #fff; }
.hero.photo-hero p.lede { color: #d7dce6; }
.hero.photo-hero .kicker { color: var(--gold-end); }

.hero.graphic-hero {
  background: linear-gradient(135deg, #050d1a 0%, #0a1830 45%, #132644 100%);
  background-size: 200% 200%;
  animation: heroGradientShift 12s ease-in-out infinite;
  color: #fff;
  overflow: hidden;
}
.hero.graphic-hero::before { display: none; }
.hero.graphic-hero h1 { color: #fff; }
.hero.graphic-hero p.lede { color: #d7dce6; }
.hero.graphic-hero .kicker { color: var(--gold-end); }

@keyframes heroGradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.hero h1 { font-family: var(--serif); font-size: 48px; line-height: 1.15; font-weight: 600; margin: 0 0 22px; max-width: 780px; }
.hero p.lede { font-size: 19px; color: #33405a; max-width: 620px; margin: 0 0 34px; }

.button-row { display: flex; flex-wrap: wrap; }
.button-row .btn { margin-right: 16px; margin-bottom: 12px; }
.button-row .btn:last-child { margin-right: 0; }

.btn {
  display: inline-block;
  padding: 14px 28px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
  border-radius: 3px;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary { background: linear-gradient(135deg, var(--gold-start), var(--gold-end)); color: var(--deep-navy); }
.btn-secondary { background: transparent; color: var(--ink-navy); border: 1.5px solid var(--ink-navy); }
.btn-secondary:hover { background: var(--ink-navy); color: var(--paper); }
.btn-secondary-light { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,0.7); }
.btn-secondary-light:hover { background: #fff; color: var(--ink-navy); }

/* ---------- Sections ---------- */

section { padding: 64px 0; }
section.alt { background: var(--paper-dim); }

.section-head { max-width: 640px; margin-bottom: 40px; }
.section-head .kicker { font-family: var(--sans); font-size: 13px; font-weight: 600; color: var(--gold-start); margin-bottom: 10px; }
.section-head h2 { font-family: var(--serif); font-size: 32px; font-weight: 600; margin: 0 0 14px; line-height: 1.25; }
.section-head p { color: var(--steel); font-size: 17px; margin: 0; }

hr.rule { border: none; border-top: 1px solid var(--hairline); margin: 0; }

/* ---------- Stat strip ---------- */

.stat-strip { display: flex; flex-wrap: wrap; padding: 36px 0; border-top: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
.stat-strip .stat { margin-right: 48px; }
.stat-strip .stat .num { font-family: var(--serif); font-size: 34px; font-weight: 600; color: var(--ink-navy); }
.stat-strip .stat .label { font-size: 14px; color: var(--steel); margin-top: 2px; }

/* ---------- Testimonials ---------- */

.testimonial { border-left: 3px solid var(--gold-start); padding-left: 24px; margin-bottom: 32px; max-width: 720px; }
.testimonial p.quote { font-family: var(--serif); font-size: 20px; font-style: italic; line-height: 1.5; margin: 0 0 12px; color: var(--ink-navy); }
.testimonial p.attrib { font-size: 14px; color: var(--steel); margin: 0; }

/* ---------- Two column (flexbox, not grid, for broad rendering compatibility) ---------- */

.two-col { display: flex; flex-wrap: wrap; align-items: flex-start; }
.two-col > div { flex: 1 1 460px; margin-right: 56px; margin-bottom: 24px; min-width: 280px; }
.two-col > div:last-child { margin-right: 0; }

/* ---------- Practice list ---------- */

.practice-list { list-style: none; margin: 0; padding: 0; }
.practice-list li { padding: 22px 0; border-top: 1px solid var(--hairline); display: flex; flex-wrap: wrap; gap: 24px; align-items: baseline; justify-content: space-between; }
.practice-list li:last-child { border-bottom: 1px solid var(--hairline); }
.practice-list h3 { font-family: var(--serif); font-size: 20px; font-weight: 600; margin: 0 0 6px; }
.practice-list p { margin: 0; color: var(--steel); font-size: 15px; max-width: 520px; }

/* ---------- Client roster ---------- */

.roster { display: flex; flex-wrap: wrap; font-family: var(--serif); font-size: 18px; color: var(--ink-navy); }
.roster span { margin: 0 16px 14px 0; display: inline-block; }
.roster span.dim { color: var(--steel); }

/* ---------- Positions ---------- */

.position-card { border: 1px solid var(--hairline); border-radius: 4px; padding: 28px; margin-bottom: 20px; background: #fff; }
.position-card .pos-head { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 12px; cursor: pointer; min-width: 0; }
.position-card .pos-head > div:first-child { min-width: 0; flex: 1 1 auto; }
.position-card h3 { font-family: var(--serif); font-size: 22px; font-weight: 600; margin: 0 0 6px; }
.position-card .meta { font-size: 14px; color: var(--steel); }
.position-card .meta span:not(:last-child)::after { content: "\2022"; margin: 0 8px; color: var(--hairline); }
.position-card .details { margin-top: 20px; padding-top: 20px; border-top: 1px solid var(--hairline); display: none; }
.position-card.open .details { display: block; }
.position-card .details ul { padding-left: 20px; margin: 12px 0; color: #33405a; }
.position-card .details li { margin-bottom: 6px; }
.toggle-indicator { font-family: var(--sans); font-size: 13px; font-weight: 600; color: var(--gold-start); white-space: nowrap; }

/* ---------- Forms ---------- */

form.apply-form, form.contact-form { max-width: 600px; }
.field { margin-bottom: 20px; }
.field label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; color: var(--ink-navy); }
.field input[type="text"], .field input[type="email"], .field input[type="tel"], .field select, .field textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--hairline); border-radius: 3px;
  font-family: var(--sans); font-size: 15px; background: #fff; color: var(--ink-navy);
}
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--gold-start); outline-offset: 1px; }
.field textarea { resize: vertical; min-height: 110px; }
.field-file { border: 1.5px dashed var(--hairline); border-radius: 4px; padding: 20px; text-align: center; background: var(--paper-dim); }
.helper-text { font-size: 13px; color: var(--steel); margin-top: 6px; }

/* ---------- Footer ---------- */

footer.site-footer { background: var(--ink-navy); color: #cbd3e0; padding: 48px 0 32px; margin-top: 40px; }
footer.site-footer .footer-row { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 32px; }
footer.site-footer h4 { font-family: var(--sans); font-size: 14px; font-weight: 600; color: #fff; margin: 0 0 14px; }
footer.site-footer a { color: #cbd3e0; }
footer.site-footer a:hover { color: #fff; }
footer.site-footer .offices { font-size: 14px; line-height: 2; }
footer.site-footer .legal { margin-top: 36px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,0.12); font-size: 13px; color: #8b93a8; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }

/* ---------- Alerts ---------- */

.alert { padding: 16px 20px; border-radius: 4px; margin-bottom: 24px; font-size: 15px; }
.alert-success { background: #eaf3ea; border: 1px solid #b7d8b8; color: #235a26; }
.alert-error { background: #fbeaea; border: 1px solid #e3b3b3; color: #7a2323; }

/* ---------- Mobile ---------- */

@media (max-width: 760px) {
  .two-col > div { flex: 1 1 100%; margin-right: 0; }
  .hero h1 { font-size: 34px; }
  header.site-header .header-row { flex-direction: column; align-items: flex-start; }
  nav.main-nav { width: 100%; }
  nav.main-nav a { margin-left: 0; margin-right: 18px; font-size: 14px; }
  .stat-strip .stat { margin-right: 28px; }
  .position-card { padding: 20px; }
  .position-card .pos-head { flex-direction: column; }
  .position-card .meta { display: block; }
  .position-card .meta span { display: inline-block; margin-bottom: 4px; }
}
