/* =====================================================
   DJR ADVISORS — Crimson / Clean White redesign
   ===================================================== */

:root {
  --crimson:       #CC2200;
  --crimson-dark:  #aa1c00;
  --crimson-faint: rgba(204, 34, 0, 0.07);
  --black:         #000000;
  --grey:          #939598;
  --white:         #ffffff;
  --off-white:     #f5f5f5;
  --border:        #e5e5e5;
  --nav-height:    80px;
  --max:           1120px;
  --radius:        10px;
  --radius-sm:     6px;
  --radius-pill:   50px;
}

/* ----- Reset ----- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; overflow-x: hidden; }
body {
  font-family: 'Quicksand', sans-serif;
  font-weight: 400;
  color: var(--black);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a  { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* ----- Typography ----- */
h1, h2, h3, h4 {
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  line-height: 1.25;
}
h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); color: var(--crimson); }
h3 { font-size: 1.15rem; color: var(--crimson); }
p  { line-height: 1.6; }

/* ----- Layout ----- */
.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 40px;
}
.section      { padding: 88px 0; }
.section--alt { background: var(--off-white); }

/* ----- Buttons ----- */
.btn {
  display: inline-block;
  padding: 13px 32px;
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.03em;
  border-radius: var(--radius-pill);
  cursor: pointer;
  border: none;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
}
.btn-coral {
  background: var(--crimson);
  color: var(--white);
}
.btn-coral:hover {
  background: var(--crimson-dark);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(204, 34, 0, 0.3);
}
.btn-white {
  background: var(--white);
  color: var(--crimson);
}
.btn-white:hover {
  background: rgba(255,255,255,0.9);
  transform: translateY(-1px);
}

/* =====================================================
   NAVIGATION
   ===================================================== */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-height);
  background: #ffffff;
  border-bottom: 1px solid #eeeeee;
  z-index: 1000;
}
.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 40px;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}
.nav-logo img {
  height: 50px;
  width: auto;
}
.nav-logo-text {
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  font-size: 1.3rem;
  color: #333333;
  letter-spacing: -0.01em;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
}
.nav-links a {
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  font-size: 0.875rem;
  color: #333333;
  letter-spacing: 0.04em;
  transition: color 0.2s;
  white-space: nowrap;
}
.nav-links a:hover, .nav-links a.active { color: var(--crimson); }
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}
.nav-toggle span {
  display: block;
  width: 24px; height: 2px;
  background: #333333;
  border-radius: 2px;
  transition: all 0.25s;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* =====================================================
   HERO — Vimeo full-bleed background video
   ===================================================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background-color: #1c1c1c; /* fallback while video loads */
}

/* ---- video layer ---- */
.hero-video-wrap {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  pointer-events: none;
}
/* 16:9 cover trick: always larger than the container */
.hero-video-wrap iframe {
  position: absolute;
  top: 50%; left: 50%;
  width: 100vw;
  height: 56.25vw;   /* 16:9 based on width */
  min-height: 100%;
  min-width: 177.78vh; /* 16:9 based on height */
  transform: translate(-50%, -50%);
  border: none;
}

/* ---- dark overlay on top of video ---- */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 1;
}

/* ---- text content above overlay ---- */
.hero-inner {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: calc(var(--nav-height) + 80px) 40px 100px;
}
.hero-text h1 {
  color: var(--white);
  margin-bottom: 20px;
  text-shadow: 0 2px 16px rgba(0,0,0,0.5);
}
.hero-text p {
  color: rgba(255,255,255,0.88);
  font-size: 1.1rem;
  line-height: 1.75;
  margin-bottom: 36px;
  max-width: 580px;
  margin-left: auto;
  margin-right: auto;
}

/* ----- Page Hero (inner pages) — light grey, no red ----- */
.page-hero {
  background: var(--off-white);
  padding: calc(var(--nav-height) + 56px) 0 56px;
  border-bottom: 1px solid var(--border);
}
.page-hero h1 { color: var(--crimson); }

/* =====================================================
   ABOUT SECTION
   ===================================================== */
.about-body { max-width: 800px; }
.about-body h2 { margin-bottom: 24px; }
.about-body p  { font-size: 1rem; line-height: 1.85; color: #333; }

/* =====================================================
   VERTICALS
   ===================================================== */
.section-eyebrow {
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--grey);
  margin-bottom: 14px;
}
.section-header        { margin-bottom: 52px; }
.section-header h2     { margin-bottom: 0; }

.verticals-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.vertical-card {
  background: var(--white);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 44px 32px;
  text-align: center;
  transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s;
}
.vertical-card:hover {
  border-color: var(--crimson);
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(204, 34, 0, 0.1);
}
.vertical-icon {
  width: 64px; height: 64px;
  background: var(--crimson-faint);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 20px;
}
.vertical-icon svg { width: 30px; height: 30px; color: var(--crimson); }
.vertical-card h3 { font-size: 1.1rem; }

/* =====================================================
   SERVICE CARDS (homepage preview + services page)
   ===================================================== */
.services-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}
.service-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.25s, transform 0.25s;
}
.service-card:hover {
  box-shadow: 0 12px 40px rgba(0,0,0,0.1);
  transform: translateY(-4px);
}
.service-card-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}
.service-card-body {
  padding: 28px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.service-card-body h3 { font-size: 1rem; }
.service-card-body p {
  font-size: 0.9rem;
  color: #444;
  flex: 1;
  line-height: 1.7;
}

/* =====================================================
   CLIENTS
   ===================================================== */
.section-intro {
  font-size: 1rem;
  color: #444;
  line-height: 1.8;
  max-width: 720px;
  margin-bottom: 56px;
}
.clients-list { display: flex; flex-direction: column; gap: 48px; }
.client-category-title {
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  color: var(--crimson);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--crimson);
}
.client-names {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 6px 24px;
}
.client-name {
  font-family: 'Quicksand', sans-serif;
  font-weight: 400;
  font-size: 0.9rem;
  color: var(--black);
  padding: 7px 0;
  border-bottom: 1px solid var(--border);
}
a.client-link {
  display: inline-block;
  color: #1a3a5c;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1.5px solid #1a3a5c;
  padding-bottom: 1px;
  transition: color 0.2s, background-color 0.2s, padding 0.2s;
}
a.client-link:hover {
  background-color: #1a3a5c;
  color: #ffffff;
  padding: 2px 6px;
  border-radius: 4px;
  border-bottom: none;
}

/* =====================================================
   TEAM
   ===================================================== */

/* Row 1: 3 fixed-width columns, centered */
.team-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 280px);
  gap: 24px;
  justify-content: center;
  margin-bottom: 28px;
}
/* Remaining rows: 2 fixed-width columns, centered */
.team-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 280px);
  gap: 28px;
  justify-content: center;
}
/* <a> grid items: fixed height matches card */
.team-grid-3 > a,
.team-grid-2 > a {
  display: block;
  height: 320px;
}
/* All cards: identical fixed dimensions, content centered */
.team-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 28px 20px;
  text-align: center;
  transition: box-shadow 0.25s, transform 0.25s;
}
.team-card:hover {
  box-shadow: 0 8px 28px rgba(204, 34, 0, 0.1);
  transform: translateY(-3px);
}
.team-avatar-svg,
.team-card svg {
  width: 100px;
  height: 100px;
  display: block;
  margin: 0 auto 16px;
}
.team-photo {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  margin: 0 auto 16px;
}
.team-name {
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  font-size: 0.975rem;
  color: var(--black);
}

/* =====================================================
   WHITEPAPERS
   ===================================================== */
.whitepaper-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px;
  display: flex;
  align-items: flex-start;
  gap: 32px;
  max-width: 680px;
  transition: box-shadow 0.25s;
}
.whitepaper-card:hover { box-shadow: 0 8px 32px rgba(0,0,0,0.08); }
.wp-icon {
  width: 56px; min-width: 56px; height: 72px;
  background: var(--crimson-faint);
  border: 1px solid rgba(204, 34, 0, 0.18);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
}
.wp-icon svg { width: 26px; height: 26px; color: var(--crimson); }
.wp-body h3  { font-size: 1.1rem; color: var(--black); margin-bottom: 10px; }
.wp-body p   { font-size: 0.9rem; color: #555; margin-bottom: 22px; line-height: 1.7; }

/* =====================================================
   CONTACT
   ===================================================== */
.contact-wrap {
  display: grid;
  grid-template-columns: 1fr 1.8fr;
  gap: 64px;
  align-items: start;
}
.contact-info h2  { margin-bottom: 12px; }
.contact-lead { font-size: 1rem; color: #444; margin-bottom: 36px; line-height: 1.75; }
.contact-detail {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}
.contact-detail svg { width: 20px; height: 20px; color: var(--crimson); flex-shrink: 0; }
.contact-detail a {
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  font-size: 0.975rem;
  color: var(--crimson);
  transition: opacity 0.2s;
}
.contact-detail a:hover { opacity: 0.75; }
.contact-form-box {
  background: var(--off-white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 44px;
}
.contact-form-box h3 {
  font-size: 1.2rem;
  color: var(--black);
  margin-bottom: 6px;
}
.form-sub { font-size: 0.875rem; color: var(--grey); margin-bottom: 28px; }
.form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 20px; }
.form-group label {
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--black);
}
.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  font-family: 'Quicksand', sans-serif;
  font-weight: 400;
  font-size: 0.925rem;
  color: var(--black);
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  -webkit-appearance: none;
}
.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--crimson);
  box-shadow: 0 0 0 3px rgba(204, 34, 0, 0.1);
}
.form-group textarea { min-height: 120px; resize: vertical; }

/* =====================================================
   FOOTER
   ===================================================== */
.footer {
  background: #f5f5f5;
  padding: 44px 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.footer-logo {
  height: 34px;
  width: auto;
  margin: 0 auto 18px;
  display: block;
}
.footer-logo-text {
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  font-size: 1.3rem;
  color: #333333;
  margin-bottom: 18px;
}
.footer p {
  font-family: 'Quicksand', sans-serif;
  font-weight: 400;
  font-size: 0.875rem;
  color: #333333;
  line-height: 1.85;
}
.footer a { color: var(--crimson); font-weight: 700; transition: color 0.2s; }
.footer a:hover { color: var(--crimson-dark); }
.footer-contact {
  font-size: 0.95rem;
  color: #333333 !important;
  font-weight: 700;
  margin-bottom: 6px;
}

/* =====================================================
   BIO PAGE
   ===================================================== */
.bio-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 56px;
  align-items: start;
}
.bio-photo-img {
  width: 100%;
  border-radius: 12px;
  display: block;
  box-shadow: 0 4px 24px rgba(0,0,0,0.1);
}
.bio-content h2 { margin-bottom: 6px; }
.bio-title {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--grey);
  margin-bottom: 28px;
}
.bio-content p {
  font-size: 1rem;
  line-height: 1.85;
  color: #333;
  margin-bottom: 18px;
}
.bio-content p:last-of-type { margin-bottom: 0; }
.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 36px;
}

/* =====================================================
   RESPONSIVE
   ===================================================== */

/* ── Tablet: 960px ── */
@media (max-width: 960px) {
  .bio-layout     { grid-template-columns: 220px 1fr; gap: 36px; }
  .team-grid-3    { grid-template-columns: repeat(3, 1fr); }
  .team-grid-2    { grid-template-columns: repeat(2, 1fr); }
  .verticals-grid { grid-template-columns: repeat(2, 1fr); }
  .services-grid  { grid-template-columns: 1fr 1fr; }
  .team-grid      { grid-template-columns: repeat(2, 1fr); }
  .contact-wrap   { grid-template-columns: 1fr; }
  .client-names   { grid-template-columns: repeat(2, 1fr); }
}

/* ── Nav hamburger: 768px ── */
@media (max-width: 768px) {
  .nav-toggle { display: flex; }
  .nav-links {
    display: none;
    position: fixed;
    top: var(--nav-height); left: 0; right: 0;
    background: #ffffff;
    flex-direction: column;
    gap: 0;
    padding: 8px 0 16px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    border-bottom: 1px solid #eeeeee;
    align-items: stretch;
    z-index: 999;
  }
  .nav-links.open { display: flex; }
  .nav-links a {
    padding: 14px 24px;
    color: #333333;
    border-bottom: 1px solid #eeeeee;
    letter-spacing: 0.06em;
  }
  .nav-links a:last-child { border-bottom: none; }
  /* Collapse 3-col team row to 2 on tablet */
  .team-grid-3 { grid-template-columns: repeat(2, 1fr); }
}

/* ── Mobile: 640px ── */
@media (max-width: 640px) {
  :root { --nav-height: 70px; }
  .container { padding: 0 20px; }
  .section   { padding: 56px 0; }

  /* hero */
  .hero-inner  { padding: calc(var(--nav-height) + 40px) 20px 60px; }
  .hero-text h1 { font-size: 2rem; max-width: 100%; }
  .hero-text p  { font-size: 1rem; }

  /* Vimeo: already covers via the 100vw/56.25vw trick — ensure no overflow */
  .hero-video-wrap { overflow: hidden; }

  /* service & vertical cards */
  .services-grid  { grid-template-columns: 1fr; }
  .verticals-grid { grid-template-columns: 1fr 1fr; }

  /* team grids — fluid, no fixed px widths */
  .team-grid      { grid-template-columns: 1fr 1fr; }
  .team-grid-3    { grid-template-columns: 1fr; }
  .team-grid-2    { grid-template-columns: 1fr; }
  .team-grid-3 > a,
  .team-grid-2 > a { height: auto; min-height: 300px; }

  /* bio page */
  .bio-layout    { grid-template-columns: 1fr; gap: 28px; }
  .bio-photo-img { max-width: 200px; margin: 0 auto; }

  /* misc */
  .contact-wrap      { grid-template-columns: 1fr; }
  .contact-form-box  { padding: 28px 20px; }
  .client-names      { grid-template-columns: 1fr; }
  .whitepaper-card   { flex-direction: column; }
  .service-card-img  { height: 180px; }
}

/* ── Small mobile: 420px ── */
@media (max-width: 420px) {
  .team-grid      { grid-template-columns: 1fr; }
  .verticals-grid { grid-template-columns: 1fr; }
  h1 { font-size: 1.75rem; }
}
