/* New Megamenu Styles (In-Progress) */

/* Overall Styles */
.navbar .megamenu {
  padding: 0rem;
}

.has-megamenu .dropdown-menu.megamenu {
  position: fixed !important;
  left: 0 !important;
  right: 0 !important;
  width: 100vw !important;
  max-width: 100vw !important;
  top: 0;
  transform: none !important;
  z-index: 9999;
  border-left: 0;
  border-right: 0;
  max-height: 85vh !important;
  overflow-y: auto;
}

.megamenu-item {
  border-radius: 0.5rem;
  transition: background-color 0.2s ease, transform 0.2s ease,
    box-shadow 0.2s ease;
}

.megamenu-item:hover,
.megamenu-item:focus {
  background-color: rgba(255, 255, 255, 0.15);
  transform: translateX(2px);
  box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.12);
}

.megamenu-tab-item.active {
  background-color: rgba(255, 255, 255, 0.08);
}

.megamenu-link-title {
  color: #ffffff;
  transition: color 0.2s ease;
}

.megamenu-item:hover .megamenu-link-title,
.megamenu-item:focus .megamenu-link-title,
.megamenu-item:focus-visible .megamenu-link-title,
.megamenu-tab-item.active .megamenu-link-title,
.dropdown-item.active .megamenu-link-title {
  color: var(--logo-orange);
}

.megamenu-icon,
.megamenu-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  flex-shrink: 0;
}

.megamenu-icon {
  width: 2.5rem;
  min-width: 2.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.megamenu-icon i {
  line-height: 1;
}

.megamenu-arrow {
  min-width: 1.5rem;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.megamenu-item:hover .megamenu-arrow,
.megamenu-item:focus .megamenu-arrow {
  transform: translateX(2px);
}

.megamenu .dropdown-item {
  white-space: normal;
}

/* Industry Dropdown Styles */
.industry-card {
  min-height: 6.75rem;
  border-radius: 0.25rem;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background-color: rgba(255, 255, 255, 0.04);
}

.industry-card:hover,
.industry-card:focus {
  border-color: rgba(255, 255, 255, 0.4);
}

.industry-card:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.7);
  outline-offset: 2px;
}

.industry-card-img {
  transition: transform 0.25s ease, opacity 0.25s ease;
  opacity: 0.9;
}

.industry-card-overlay::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.7) 0%,
    rgba(0, 0, 0, 0.5) 38%,
    rgba(0, 0, 0, 0.2) 65%,
    rgba(0, 0, 0, 0.12) 100%
  );
}

.industry-card:hover::before,
.industry-card:focus::before {
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.9) 0%,
    rgba(0, 0, 0, 0.68) 45%,
    rgba(0, 0, 0, 0.3) 75%,
    rgba(0, 0, 0, 0.18) 100%
  );
}

.industry-card-content {
  min-height: 6rem;
  padding: 0.5rem !important;
}

.industry-card-content .small,
.industry-card-content p,
.industry-card-cta {
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
}

.industry-card-cta {
  display: inline-flex;
  align-items: center;
  font-size: 0.75rem;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.92);
  letter-spacing: 0.03em;
}

.industry-card-cta i {
  transition: transform 0.2s ease;
}

.industry-card:hover .industry-card-img,
.industry-card:focus .industry-card-img {
  transform: scale(1.1);
  opacity: 0.82;
}

.industry-card:hover .industry-card-cta,
.industry-card:focus .industry-card-cta {
  color: rgba(255, 255, 255, 1);
}

.industry-card:hover .industry-card-cta i,
.industry-card:focus .industry-card-cta i {
  transform: translateX(2px);
}

/* News Dropdown Styles */
.news-headline-block {
  border-left: 3px solid var(--logo-orange);
  padding-left: 1rem;
  max-width: 32rem;
}

.news-feature-card {
  min-height: 11rem;
}

.white-paper-card-overlay::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.85) 0%,
    rgba(0, 0, 0, 0.75) 38%,
    rgba(0, 0, 0, 0.65) 85%,
    rgba(0, 0, 0, 0.55) 100%
  );
}

.white-paper-card:hover::before,
.white-paper-card:focus::before {
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.95) 0%,
    rgba(0, 0, 0, 0.85) 30%,
    rgba(0, 0, 0, 0.75) 90%,
    rgba(0, 0, 0, 0.7) 100%
  );
}

/* Podcasts & Events Dropdown Styles */
.event-highlight-cta {
  transition: background-color 0.2s ease, color 0.2s ease,
    border-color 0.2s ease;
}

.event-highlight-card:hover .event-highlight-cta,
.event-highlight-card:focus .event-highlight-cta,
.event-highlight-card:focus-visible .event-highlight-cta {
  background-color: var(--logo-orange);
  color: #ffffff;
  border-color: var(--logo-orange);
}

.outlook-icon {
  width: 0.85rem;
  min-width: 0.85rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* Mobile */

@media (max-width: 991.98px) {
  .navbar .has-megamenu {
    position: relative !important;
  }

  .has-megamenu .border-bottom {
    border-bottom: 0 !important;
  }

  .has-megamenu .dropdown-menu.megamenu {
    position: static !important;
    left: auto !important;
    right: auto !important;
    top: auto !important;
    width: 100% !important;
    max-width: 100% !important;
    transform: none !important;
    background-color: transparent;
    box-shadow: none;
    max-height: none;
    overflow-y: auto;
    overflow-x: hidden;
    margin-top: 0.5rem;
    border-left: 0;
    border-right: 0;
  }

  .navbar .megamenu-2 {
    padding: 0.25rem 0 1rem 0;
    backdrop-filter: none;
  }

  .header-mobile-megamenu-left {
    border-right: 0 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    padding-bottom: 1rem !important;
    margin-bottom: 0.25rem;
  }

  .header-mobile-megamenu-right {
    padding-left: 0 !important;
  }

  .header-mobile-megamenu-subcol {
    border-left: 0 !important;
    padding-left: 0 !important;
  }

  .header-mobile-megamenu-subcol + .header-mobile-megamenu-subcol {
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    margin-top: 1rem;
    padding-top: 1rem !important;
  }

  .header-mobile-megamenu-tabs .megamenu-tab-item {
    padding-top: 0.875rem !important;
    padding-bottom: 0.875rem !important;
  }

  .header-mobile-megamenu-tabs .megamenu-arrow {
    display: none;
  }

  .navbar .megamenu .tab-pane.fade {
    transition: none;
  }

  .has-megamenu .nav-link > span > span:first-child {
    position: relative;
    color: #fff;
    transition: color 0.2s ease;
  }

  .has-megamenu .nav-link > span > span:first-child::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -0.2rem;
    width: 100%;
    height: 2px;
    background-color: var(--logo-orange);
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.25s ease;
  }

  .has-megamenu.mobile-submenu-open .nav-link > span > span:first-child {
    color: var(--logo-orange) !important;
  }

  .has-megamenu.mobile-submenu-open .nav-link > span > span:first-child::after {
    transform: scaleX(1);
  }

  .has-megamenu .nav-link > span > span:first-child {
    position: relative;
    color: #fff;
    transition: color 0.2s ease;
  }

  .has-megamenu .nav-link > span > span:first-child::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -0.2rem;
    width: 100%;
    height: 2px;
    background-color: var(--logo-orange);
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.25s ease;
  }

  .has-megamenu.mobile-submenu-open .nav-link > span > span:first-child {
    color: var(--logo-orange) !important;
  }

  .has-megamenu.mobile-submenu-open .nav-link > span > span:first-child::after {
    transform: scaleX(1);
  }

  .header-mobile-pane-slot {
    overflow: hidden;
    /* padding-bottom: 0.75rem; */
    max-height: 0;
    opacity: 0;
    transition: max-height 0.3s ease, opacity 0.2s ease, margin-top 0.3s ease;
  }

  .header-mobile-pane-slot.is-open {
    opacity: 1;
    margin-top: 0.25rem;
  }

  .header-mobile-pane-slot > .tab-pane {
    display: block;
  }

  .header-mobile-toggle-tabs .megamenu-tab-item .megamenu-arrow i {
    transition: transform 0.25s ease, opacity 0.2s ease;
  }

  .header-mobile-toggle-tabs
    .megamenu-tab-item.mobile-tab-open
    .megamenu-arrow
    i {
    transform: rotate(180deg);
  }

  .header-mobile-pane-slot > .tab-pane.fade:not(.show) {
    opacity: 0;
  }

  .header-mobile-pane-slot > .tab-pane.fade.show {
    opacity: 1;
  }

  .header-mobile-pane-slot .border-start {
    border-left: 0 !important;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    margin-top: 1rem;
    padding-top: 1rem !important;
    padding-left: 0 !important;
  }
}
