/* ================================================================
   VEGAN SCIENTIST | custom.css
   Hugo theme: Introduction
   Homepage hero only; navigation and article styles kept separate.
   ================================================================ */

/* 1. HOMEPAGE HERO: the background never appears on article pages. */
#top.hero {
  background-image:
    linear-gradient(rgba(5, 12, 30, 0.50), rgba(5, 12, 30, 0.62)),
    url("/img/home-background.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  min-height: 380px;
}

/* Homepage title and payoff */
#top.hero .bold-title,
#top.hero .subtitle,
#top.hero .subtitle p {
  color: #fff !important;
  opacity: 1;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.72);
}

#top.hero .subtitle {
  font-size: clamp(1.2rem, 2vw, 1.7rem);
  line-height: 1.5;
}

/* 2. HOMEPAGE NAVIGATION: white text, turquoise on hover. */
#top.hero .navbar .navbar-item,
#top.hero .navbar .navbar-item:link,
#top.hero .navbar .navbar-item:visited {
  color: #fff !important;
  background-color: transparent !important;
  transition: color .18s ease, background-color .18s ease;
}

#top.hero .navbar .navbar-item:hover,
#top.hero .navbar .navbar-item:focus-visible {
  color: #5eead4 !important;
  background-color: rgba(8, 25, 45, .40) !important;
  text-decoration: none;
}

/* 3. ARTICLE AND OTHER INTERNAL PAGES: dark menu on light background. */
#top.section .navbar .navbar-item,
#top.section .navbar .navbar-item:link,
#top.section .navbar .navbar-item:visited {
  color: #334155 !important;
  background-color: transparent !important;
  transition: color .18s ease, background-color .18s ease;
}

#top.section .navbar .navbar-item:hover,
#top.section .navbar .navbar-item:focus-visible {
  color: #0f766e !important;
  background-color: rgba(15, 118, 110, .08) !important;
  text-decoration: none;
}

/* 4. CLICKABLE HEADINGS INSIDE ARTICLES: dark-teal hover only. */
#top.section .markdown :is(h2, h3, h4) a {
  color: inherit;
  background-color: transparent;
  transition: color .18s ease;
}

#top.section .markdown :is(h2, h3, h4) a:hover,
#top.section .markdown :is(h2, h3, h4) a:focus-visible {
  color: #0f766e !important;
  background-color: transparent !important;
  text-decoration: none;
}

/* Keyboard navigation remains visible without introducing white blocks. */
#top .navbar .navbar-item:focus-visible,
#top.section .markdown :is(h2, h3, h4) a:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
  border-radius: 3px;
}

/* 5. MOBILE */
@media (max-width: 768px) {
  #top.hero {
    min-height: 300px;
    background-position: center;
  }

  #top.hero .bold-title {
    font-size: clamp(2rem, 9vw, 2.6rem);
  }

  #top.hero .subtitle {
    font-size: 1.15rem;
  }

  /* Bulma's expanded mobile menu needs a readable background. */
  #top.hero .navbar-menu.is-active {
    background-color: rgba(8, 20, 38, .95);
  }

  #top.section .navbar-menu.is-active {
    background-color: #fff;
  }
}

@media (prefers-reduced-motion: reduce) {
  #top .navbar .navbar-item,
  #top.section .markdown :is(h2, h3, h4) a {
    transition: none;
  }
}
