#c4r-nav {
  --w: 1180px;
  --h: 64px;
  --r: 90px;
  --padX: 22px;
  --shadow: 0 10px 26px rgba(0, 0, 0, 0.12);
  --text: #32475a;
  --brand-green: #2f855a;
  font-family: "Open Sans", system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, "Helvetica Neue", Arial, sans-serif;
}

#c4r-nav .nav-wrap {
  position: fixed;
  left: 50%;
  top: 18px;
  transform: translateX(-50%);
  width: min(var(--w), 92vw);
  z-index: 300001;
}

#c4r-nav .nav-inner {
  height: var(--h);
  padding: 0 var(--padX);
  background: #fff;
  border-radius: var(--r);
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 16px;
}

#c4r-nav .nav-logo {
  display: flex;
  align-items: center;
  min-width: 120px;
}

#c4r-nav .nav-logo img {
  height: auto;
  max-height: calc(var(--h) - 18px);
  width: auto;
  display: block;
}

#c4r-nav .nav-menu {
  display: flex;
  justify-content: center;
  gap: 22px;
  min-width: 0;
}

#c4r-nav .nav-menu a {
  position: relative;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  color: var(--text);
  padding: 0 2px;
}

#c4r-nav .nav-tools {
  display: flex;
  align-items: center;
  gap: 12px;
}

#c4r-nav .flag-pill,
.c4r-country-selector .flag-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 0 10px 0 8px;
  border-radius: 999px;
  border: 1px solid #e7ebf0 !important;
  background: #fff !important;
  color: #22313f !important;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  font-family: "Open Sans", system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, "Helvetica Neue", Arial, sans-serif;
  appearance: none;
  -webkit-appearance: none;
  box-shadow: none;
}

#c4r-nav .fi-wrap,
.c4r-country-selector .fi-wrap {
  display: inline-flex;
  width: 22px;
  height: 16px;
  border-radius: 3px;
  overflow: hidden;
}

#c4r-nav .fi,
.c4r-country-selector .fi {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

#c4r-nav .flag-text,
.c4r-country-selector .flag-text {
  white-space: nowrap;
}

#c4r-nav .flag-arrow,
.c4r-country-selector .flag-arrow {
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid #22313f;
  opacity: 0.8;
  transform: translateY(1px);
}

#c4r-nav .cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  text-decoration: none;
  color: #fff;
  background: var(--brand-green);
  font-weight: 700;
  font-size: 13px;
  box-shadow: 0 6px 14px rgba(47, 133, 90, 0.18);
}

#c4r-nav .person-ic {
  margin-right: 8px;
  font-size: 20px;
  line-height: 1;
}

.c4r-country-selector {
  display: inline-flex;
}

.c4r-flag-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  z-index: 400000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.c4r-flag-modal {
  width: min(820px, 96vw);
  max-height: 90vh;
  overflow-y: auto;
  background: rgba(255, 255, 255, 0.82);
  border-radius: 10px;
  padding: 20px 18px 18px;
  position: relative;
}

.c4r-close-lightbox {
  position: absolute;
  top: 6px;
  right: 10px;
  border: 0 !important;
  background: transparent !important;
  font-size: 36px;
  line-height: 1;
  cursor: pointer;
  color: #1f2937 !important;
  padding: 0 !important;
  margin: 0 !important;
  width: auto !important;
  height: auto !important;
  min-width: 0 !important;
  min-height: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  appearance: none;
  -webkit-appearance: none;
}

#flag-lightbox #close-lightbox {
  border: 0 !important;
  background: transparent !important;
  color: #1f2937 !important;
  box-shadow: none !important;
  border-radius: 0 !important;
}

.flag-grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 12px;
  justify-items: center;
  padding: 8px 0;
}

.c4r-country-option {
  display: block;
  text-decoration: none;
  line-height: 0;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
}

.c4r-country-option:hover {
  opacity: 0.92;
}

.c4r-country-option img {
  width: 75px;
  height: auto;
  display: block;
  border-radius: 0 !important;
}

.c4r-country-option span,
#flag-lightbox .flag-grid a span {
  display: none !important;
}

#flag-lightbox .flag-grid a {
  display: block !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
}

#flag-lightbox .flag-grid a img {
  width: 75px !important;
  height: auto !important;
  border-radius: 0 !important;
  display: block !important;
}

.c4r-spanish-note {
  margin-top: 20px;
  color: #3a3a3a;
  font-size: 16px;
}

.c4r-spanish-note a {
  color: #14a3ff;
  text-decoration: none;
}

.c4r-spanish-note a:hover {
  text-decoration: underline;
}

body.c4r-flag-open #flag-lightbox {
  display: flex;
}

@media (max-width: 1200px) {
  #c4r-nav .nav-menu {
    display: none;
  }

  #c4r-nav .cta {
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 50%;
  }

  #c4r-nav .cta .cta-text {
    display: none;
  }

  #c4r-nav .person-ic {
    margin-right: 0;
  }
}

@media (max-width: 980px) {
  #c4r-nav {
    --w: 94vw;
    --h: 58px;
    --r: 54px;
    --padX: 14px;
  }

  #c4r-nav .flag-pill .flag-text {
    display: none;
  }

  .flag-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
  }

  .c4r-country-option img {
    width: 64px;
  }
}
