/* Astrolab Consulting — premium consulting brand
   Charcoal + teal #156779 | Source Serif 4 + DM Sans */

:root {
  --charcoal-950: #0c1116;
  --charcoal-900: #141a22;
  --charcoal-800: #1c2430;
  --charcoal-700: #2a3444;
  --slate-600: #52607a;
  --slate-500: #64748b;
  --slate-400: #94a3b8;
  --mist: #e8eef1;
  --cream: #f6f8f9;
  --white: #ffffff;
  --teal-900: #0a3d48;
  --teal-800: #0f4c5c;
  --teal-700: #156779;
  --teal-600: #1a8499;
  --teal-100: #dcecf0;
  --teal-50: #eef5f7;
  --border: rgba(20, 26, 34, 0.1);
  --border-strong: rgba(21, 103, 121, 0.28);
  --shadow-sm: 0 1px 2px rgba(12, 17, 22, 0.04);
  --shadow-md: 0 10px 32px rgba(12, 17, 22, 0.08);
  --shadow-lg: 0 22px 56px rgba(12, 17, 22, 0.14);
  --font-display: "Source Serif 4", Georgia, "Times New Roman", serif;
  --font-body: "DM Sans", "Helvetica Neue", Arial, sans-serif;
  --max: 1120px;
  --header-h: 4.5rem;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1rem);
}

body {
  font-family: var(--font-body);
  color: var(--charcoal-900);
  background: var(--cream);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; height: auto; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
strong { font-weight: 600; color: var(--charcoal-950); }

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.75rem;
}

/* —— Header —— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  backdrop-filter: blur(18px) saturate(1.15);
  -webkit-backdrop-filter: blur(18px) saturate(1.15);
  background: rgba(246, 248, 249, 0.9);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.nav {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  position: relative;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-shrink: 0;
}

.brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--teal-800);
}

.brand-name {
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  color: var(--charcoal-900);
}

.brand-name span {
  font-weight: 500;
  color: var(--slate-500);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.15rem 1.75rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--slate-600);
}

.nav-links a {
  position: relative;
  padding: 0.35rem 0;
  transition: color 0.25s var(--ease);
}

.nav-links a:hover { color: var(--teal-800); }

.nav-cta {
  margin-left: 0.35rem;
  font-size: 0.82rem !important;
  font-weight: 600 !important;
  color: var(--white) !important;
  background: var(--charcoal-900);
  padding: 0.55rem 1rem !important;
  border-radius: 4px;
  transition: background 0.25s var(--ease), transform 0.25s var(--ease);
}

.nav-cta:hover {
  background: var(--teal-800) !important;
  color: var(--white) !important;
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  background: var(--white);
  border: 1px solid var(--border-strong);
  border-radius: 4px;
  padding: 0.45rem 0.75rem;
  cursor: pointer;
  color: var(--teal-800);
  font-size: 0.82rem;
  font-family: var(--font-body);
  font-weight: 600;
}

/* —— Typography —— */
.eyebrow {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal-600);
  margin-bottom: 1rem;
}

.eyebrow--light { color: rgba(255, 255, 255, 0.62); }

.display {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--charcoal-950);
}

.lead {
  font-size: 1.05rem;
  color: var(--slate-600);
  line-height: 1.75;
  max-width: 40rem;
}

.body-copy {
  font-size: 1.02rem;
  color: var(--slate-600);
  line-height: 1.75;
  max-width: 40rem;
}

.accent-rule {
  width: 40px;
  height: 2px;
  background: var(--teal-700);
  margin-bottom: 1.25rem;
}

.accent-rule--light { background: rgba(255, 255, 255, 0.4); }

/* —— Sections —— */
.section {
  padding: 5.5rem 0;
  position: relative;
}

.section--white {
  background: var(--white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section--mist {
  background: var(--mist);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section--dark {
  background:
    linear-gradient(160deg, var(--charcoal-950) 0%, var(--teal-900) 48%, var(--charcoal-900) 100%);
  color: rgba(255, 255, 255, 0.88);
}

.section--dark .display { color: var(--white); }
.section--dark .lead,
.section--dark p { color: rgba(255, 255, 255, 0.76); }

.section-intro { margin-bottom: 3rem; max-width: 40rem; }

.section-title {
  font-size: clamp(1.75rem, 3vw, 2.35rem);
  max-width: 22ch;
}

/* —— Buttons —— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.92rem;
  padding: 0.9rem 1.45rem;
  border-radius: 4px;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition:
    background 0.25s var(--ease),
    color 0.25s var(--ease),
    border-color 0.25s var(--ease),
    transform 0.25s var(--ease),
    box-shadow 0.25s var(--ease);
}

.btn-primary {
  background: var(--teal-700);
  color: var(--white);
  box-shadow: 0 2px 12px rgba(21, 103, 121, 0.28);
}

.btn-primary:hover {
  background: var(--teal-800);
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(21, 103, 121, 0.32);
}

.btn-secondary {
  background: transparent;
  color: var(--charcoal-900);
  border-color: rgba(20, 26, 34, 0.22);
}

.btn-secondary:hover {
  border-color: var(--teal-700);
  color: var(--teal-800);
  transform: translateY(-1px);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  align-items: center;
  margin-top: 2rem;
}

/* —— Hero —— */
.hero {
  position: relative;
  min-height: min(90vh, 780px);
  display: flex;
  align-items: stretch;
  overflow: hidden;
  background: var(--charcoal-950);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  width: 100%;
  max-width: none;
  min-height: inherit;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 5.5rem clamp(1.5rem, 4vw, 4.5rem) 5rem;
  position: relative;
  z-index: 2;
  background:
    linear-gradient(105deg, rgba(12, 17, 22, 0.97) 0%, rgba(12, 17, 22, 0.92) 70%, rgba(12, 17, 22, 0.55) 100%);
  color: var(--white);
}

.hero-copy .eyebrow { color: rgba(42, 159, 181, 0.9); }

.hero h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.15rem, 4.2vw, 3.35rem);
  line-height: 1.15;
  letter-spacing: -0.025em;
  color: var(--white);
  max-width: 14ch;
  margin-bottom: 1.4rem;
}

.hero-sub {
  font-size: clamp(1rem, 1.4vw, 1.12rem);
  color: rgba(255, 255, 255, 0.78);
  max-width: 34rem;
  line-height: 1.75;
}

.hero .btn-secondary {
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.35);
}

.hero .btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.65);
  color: var(--white);
}

.hero-media {
  position: relative;
  min-height: 100%;
  overflow: hidden;
}

.hero-media .media-frame {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center 30%;
}

.hero-media .media-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(12, 17, 22, 0.75) 0%, transparent 28%),
    linear-gradient(180deg, rgba(12, 17, 22, 0.2) 0%, rgba(12, 17, 22, 0.55) 100%);
}

.hero-media-caption {
  position: absolute;
  left: 1.5rem;
  right: 1.5rem;
  bottom: 1.5rem;
  z-index: 2;
  padding: 1rem 1.15rem;
  background: rgba(12, 17, 22, 0.72);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-left: 3px solid var(--teal-600);
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.82rem;
  line-height: 1.5;
  max-width: 22rem;
}

.hero-media-caption strong {
  display: block;
  color: var(--white);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}

/* —— About split —— */
.split {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 3.5rem;
  align-items: start;
}

/* —— Offices —— */
.office-block {
  margin-top: 3.5rem;
  padding-top: 3rem;
  border-top: 1px solid var(--border);
}

.office-block:first-of-type {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.office-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 3rem;
  align-items: center;
}

.office-grid--reverse .office-media { order: 2; }
.office-grid--reverse .office-copy { order: 1; }

.media-panel {
  position: relative;
  aspect-ratio: 5 / 4;
  border-radius: 2px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}

.media-panel .fill-bg {
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
}

.panel-frame {
  padding: 0.55rem;
  background: var(--white);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
}

.panel-frame .media-panel {
  box-shadow: none;
  border: none;
}

.office-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal-600);
  margin-bottom: 0.7rem;
}

.office-title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.5vw, 1.95rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--charcoal-950);
  margin-bottom: 1rem;
  line-height: 1.25;
}

.office-def {
  font-size: 1.02rem;
  color: var(--slate-600);
  line-height: 1.75;
  margin-bottom: 1.5rem;
}

.capability-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.capability-list li {
  font-size: 0.98rem;
  color: var(--slate-600);
  line-height: 1.65;
  padding-left: 1.1rem;
  border-left: 2px solid var(--teal-100);
}

.capability-list strong {
  color: var(--teal-800);
}

.office-summary {
  margin-top: 1.5rem;
  font-size: 0.98rem;
  color: var(--slate-600);
  line-height: 1.7;
  padding: 1.15rem 1.25rem;
  background: var(--teal-50);
  border-left: 3px solid var(--teal-700);
}

/* —— Phases —— */
.phases {
  margin-top: 2.75rem;
  border-top: 1px solid rgba(20, 26, 34, 0.14);
}

.phase-row {
  display: grid;
  grid-template-columns: 5rem 1fr;
  gap: 1.75rem;
  padding: 2.15rem 0;
  border-bottom: 1px solid var(--border);
  transition: background 0.3s var(--ease);
}

.phase-row:hover {
  background: linear-gradient(90deg, rgba(21, 103, 121, 0.05), transparent 55%);
}

.phase-num {
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 600;
  color: var(--teal-700);
  line-height: 1;
  opacity: 0.85;
}

.phase-body h3 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--charcoal-950);
  margin-bottom: 0.55rem;
}

.phase-body p {
  font-size: 1.02rem;
  color: var(--slate-600);
  line-height: 1.75;
  max-width: 40rem;
}

/* —— Contact —— */
.wrap--narrow {
  max-width: 40rem;
}

.contact-email {
  margin-top: 1.75rem;
}

.contact-email a {
  color: var(--teal-700);
  font-weight: 600;
  font-size: 1.15rem;
  letter-spacing: 0.01em;
}

.contact-email a:hover { color: var(--teal-800); }

/* —— Footer —— */
.site-footer {
  background: var(--charcoal-950);
  color: rgba(255, 255, 255, 0.7);
  padding: 4rem 0 2.25rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1.2fr;
  gap: 2.5rem 2rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-brand .brand-name { color: var(--white); }
.footer-brand .brand-name span { color: rgba(255, 255, 255, 0.45); }

.footer-about {
  margin-top: 1.1rem;
  font-size: 0.9rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.5);
  max-width: 24rem;
}

.footer-col h4 {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.38);
  margin-bottom: 1rem;
}

.footer-col ul {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.footer-col a {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
  transition: color 0.25s var(--ease);
}

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

.footer-bottom {
  padding-top: 1.75rem;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.35);
}

/* —— Motion —— */
@keyframes fadeUp {
  from { opacity: 0.01; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

.reveal { animation: fadeUp 0.85s var(--ease) both; }
.reveal-d1 { animation-delay: 0.1s; }
.reveal-d2 { animation-delay: 0.2s; }
.reveal-d3 { animation-delay: 0.3s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { animation: none; }
  html { scroll-behavior: auto; }
}

/* —— Responsive —— */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; min-height: auto; }
  .hero { min-height: auto; }

  .hero-copy {
    padding: 3.5rem 1.5rem 2.75rem;
    background: var(--charcoal-950);
  }

  .hero h1 { max-width: none; }

  .hero-media {
    min-height: 280px;
    order: -1;
  }

  .hero-media .media-frame {
    position: relative;
    inset: auto;
    height: 280px;
  }

  .split,
  .office-grid,
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .office-grid--reverse .office-media,
  .office-grid--reverse .office-copy { order: unset; }

  .phase-row {
    grid-template-columns: 3.5rem 1fr;
    gap: 1.15rem;
  }
}

@media (max-width: 720px) {
  .nav-links { display: none; }
  .nav-toggle { display: block; }

  .nav.is-open .nav-links {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(246, 248, 249, 0.98);
    padding: 1rem 1.5rem 1.35rem;
    border-bottom: 1px solid var(--border);
    gap: 0.85rem;
    box-shadow: var(--shadow-md);
  }

  .nav-cta {
    margin-left: 0 !important;
    width: 100%;
    text-align: center;
    justify-content: center;
  }

  .section { padding: 4rem 0; }
  .wrap { padding: 0 1.35rem; }
}
