/* =========================================================
   BUTTON — START
   Reusable button component. Three variants:
   - .btn--primary  → solid brand purple (used for most CTAs)
   - .btn--dark     → solid dark navy (used for the hero CTA,
                      matching the Section 1 reference exactly)
   - .btn--secondary → white / bordered (pairs with either)
   ========================================================= */

.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: 16px 28px;
  border-radius: 8px;
  white-space: nowrap;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), background-color var(--transition-fast);
}

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

.btn--primary:hover {
  background-color: var(--color-dark-purple);
  box-shadow: var(--shadow-button);
  transform: translateY(-1px);
}

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

.btn--dark:hover {
  background-color: var(--color-black);
  transform: translateY(-1px);
}

.btn--secondary {
  background-color: var(--color-white);
  color: var(--color-primary-text);
  border: 1px solid var(--color-light-gray);
}

.btn--secondary:hover {
  border-color: var(--color-dark-gray);
  transform: translateY(-1px);
}

/* Arrow icon inside buttons/links — nudges forward on hover
   to reinforce the "go" action without a flashy effect. */
.btn__icon {
  display: inline-flex;
  transition: transform var(--transition-fast);
}

.btn:hover .btn__icon {
  transform: translate(2px, -2px);
}

/* =========================================================
   BUTTON — END
   ========================================================= */


/* =========================================================
   HEADER / NAVIGATION — START
   Sticky top navigation. Shared across every page of the site.
   ========================================================= */

.site-header {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  z-index: var(--z-header);
  background-color: var(--color-white);
  transition: box-shadow var(--transition-normal);
}

/* Applied via JS once the page has scrolled, to lift the header
   off the content beneath it without a shadow on initial load. */
.site-header.is-scrolled {
  box-shadow: var(--shadow-soft);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-lg);
  padding-block: 22px;
}

.navbar__logo img {
  height: 28px;
  width: auto;
}

/* Desktop nav links, centered between logo and CTA */
.navbar__links {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
}

.navbar__links .nav-link {
  position: relative;
  padding-block: 4px;
}

/* Understated underline-on-hover rather than a color change,
   keeps navigation minimal per the brand direction. */
.navbar__links .nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0%;
  height: 2px;
  background-color: var(--color-primary-purple);
  transition: width var(--transition-fast);
}

.navbar__links .nav-link:hover::after,
.navbar__links .nav-link:focus-visible::after {
  width: 100%;
}

/* Small dropdown-indicator chevron for nav items that represent a
   category (What We Do / Who We Are / Careers), matching the
   pattern of a plain caret next to the label with no extra weight
   or color — same treatment on desktop and in the mobile panel. */
.nav-link--caret {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.nav-link__caret {
  display: inline-flex;
  color: currentColor;
}

.navbar__cta {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

/* Hamburger toggle — hidden on desktop, shown on mobile via responsive.css */
.mobile-menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-small);
  color: var(--color-primary-text);
}

.mobile-menu-toggle i {
  display: block;
  font-size: 20px;
  line-height: 1;
  transition: opacity var(--transition-fast), transform var(--transition-fast);
}

.mobile-menu-toggle__close {
  display: none !important;
}

/* Font Awesome hamburger becomes the Font Awesome X when the menu opens. */
.mobile-menu-toggle[aria-expanded="true"] .mobile-menu-toggle__bars {
  display: none !important;
}

.mobile-menu-toggle[aria-expanded="true"] .mobile-menu-toggle__close {
  display: block !important;
}

/* Full-screen overlay panel (not an inline dropdown), so it fully
   covers the hero underneath with no content peeking below it.
   `top` is set at runtime by main.js to the navbar's real rendered
   height — deliberately not hardcoded, since that height differs
   by content/font-loading and a wrong guess would either leave a
   gap or clip the panel.
   Positioned with opacity/transform/visibility (not display) so
   opening and closing can transition smoothly. */
.mobile-menu {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: var(--z-mobile-menu);
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
  padding: var(--space-lg) var(--page-padding-mobile) var(--space-2xl);
  background-color: var(--color-white);
  border-top: 1px solid var(--color-light-gray);
  overflow-y: auto;

  /* Closed state: invisible and non-interactive, nudged up slightly
     so opening reads as a gentle downward reveal. */
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-12px);
  transition:
    opacity var(--transition-normal),
    transform var(--transition-normal),
    visibility 0s linear var(--transition-normal);
}

.mobile-menu.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
  transition:
    opacity var(--transition-normal),
    transform var(--transition-normal),
    visibility 0s linear 0s;
}

/* Users who prefer reduced motion still get the fade, just without
   the added vertical motion (base reduced-motion rule in globals.css
   already shortens the duration to near-instant). */
@media (prefers-reduced-motion: reduce) {
  .mobile-menu {
    transform: none;
  }
}

.mobile-menu .nav-link {
  font-size: 18px;
}

.mobile-menu {
  max-height: calc(100dvh - 68px);
}

.mobile-menu .btn {
  align-self: flex-start;
}

/* =========================================================
   HEADER / NAVIGATION — END
   ========================================================= */


/* =========================================================
   AVATAR STACK + RATING — START
   Overlapping avatar circles with a "+" overflow indicator,
   paired with a star rating line. Used in the hero and can be
   reused anywhere social proof is needed.
   ========================================================= */

.avatar-stack {
  display: flex;
  align-items: center;
}

.avatar-stack__item {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2px solid var(--color-white);
  margin-left: -12px;
  overflow: hidden;
  flex-shrink: 0;
}

.avatar-stack__item:first-child {
  margin-left: 0;
}

.avatar-stack__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* The "+" indicator that hints at more people beyond the stack */
.avatar-stack__more {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2px solid var(--color-white);
  margin-left: -12px;
  background-color: var(--color-primary-purple);
  color: var(--color-white);
  font-family: var(--font-primary);
  font-weight: var(--font-bold);
  font-size: 18px;
  flex-shrink: 0;
}

.rating {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  margin-top: var(--space-md);
}

.rating__icon {
  color: var(--color-primary-purple);
  flex-shrink: 0;
}

.rating__text {
  font-family: var(--font-primary);
  font-weight: var(--font-medium);
  font-size: 15px;
  color: var(--color-primary-text);
}

/* =========================================================
   AVATAR STACK + RATING — END
   ========================================================= */
