/* ── Gallery: uniform image sizes ── */
figure.half figcaption,
figure.third figcaption {
  display: none;
}

figure.half,
figure.third {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 1em 0;
}

figure.half > a,
figure.third > a {
  flex: 1 1 0;
  overflow: hidden;
  min-width: 0;
}

figure.half > a img,
figure.third > a img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.2s ease;
}

figure.half > a img:hover,
figure.third > a img:hover {
  transform: scale(1.03);
}

/* ── Custom lightbox ── */
#custom-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.88);
  z-index: 99999;
  align-items: center;
  justify-content: center;
}

#custom-lightbox.active {
  display: flex;
}

#custom-lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.6);
}

#custom-lightbox-close {
  position: fixed;
  top: 16px;
  right: 20px;
  width: 44px;
  height: 44px;
  background: rgba(255,255,255,0.15);
  border: 2px solid rgba(255,255,255,0.6);
  color: #fff;
  font-size: 1.4rem;
  line-height: 40px;
  text-align: center;
  border-radius: 50%;
  cursor: pointer;
  z-index: 100000;
  transition: background 0.15s ease;
}

#custom-lightbox-close:hover {
  background: rgba(255,255,255,0.35);
}

/* ── Search overlay ── */
.search-content {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 9998;
  background: #fff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  padding: 1.5rem 2rem;
}

.search-content.is--visible {
  display: block;
}

.search-content .search-input {
  width: 100%;
  font-size: 1.1rem;
  border: none;
  border-bottom: 2px solid #ddd;
  outline: none;
  padding: 0.4rem 0;
  background: transparent;
}

#results-container {
  margin-top: 1rem;
  max-height: 50vh;
  overflow-y: auto;
  list-style: none;
  padding: 0;
}

#results-container li a {
  display: block;
  padding: 0.4rem 0;
  color: #333;
  text-decoration: none;
  border-bottom: 1px solid #f0f0f0;
}

#results-container li a:hover {
  color: #000;
}

/* ── Footer — Auburn theme ── */
.page__footer {
  background: #03244D !important;
}

.page__footer-copyright,
.page__footer-copyright a {
  color: #e2e8f0 !important;
}

.page__footer .social-icons a,
.page__footer a {
  color: #E87722 !important;
}

.page__footer a:hover {
  color: #fff !important;
}

/* ── Offset page content below fixed nav ── */
body {
  padding-top: 50px;
}

@media (max-width: 768px) {
  body {
    padding-top: 120px;
  }
}

/* ── Masthead full width, no white space, sharp bottom line ── */
.masthead {
  margin: 0 !important;
  padding: 0 !important;
  background: #03244D !important;
  border-bottom: none !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.18) !important;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
}

/* Light text on dark nav */
.masthead .site-title,
.masthead .site-title:visited {
  color: #E87722 !important;
}

.masthead .visible-links a,
.masthead .nav-parent-label,
.masthead .search__toggle {
  color: #e2e8f0 !important;
}

.masthead .visible-links a:hover,
.masthead .nav-parent-label:hover {
  color: #fff !important;
}

/* Dropdown items stay dark on white background */
.masthead .visible-links .dropdown-menu li a,
.masthead .dropdown-menu li a {
  color: #111 !important;
}

.masthead .visible-links .dropdown-menu li a:hover,
.masthead .dropdown-menu li a:hover {
  color: #000 !important;
}

.masthead__inner-wrap {
  max-width: 1280px;
  padding-top: 0.3rem;
  padding-bottom: 0.3rem;
  padding-left: 1rem;
  padding-right: 1rem;
  margin: 0 auto;
}

.greedy-nav {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

/* ── Mobile: hide Follow button, show social links horizontally ── */
@media (max-width: 925px) {
  .author__urls-wrapper > button {
    display: none !important;
  }

  .author__urls {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 0.4rem 1.2rem;
    list-style: none !important;
    padding: 0.4rem 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
    border: none !important;
    background: transparent !important;
    position: static !important;
  }

  .author__urls li a {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.82rem;
    white-space: nowrap;
  }
}

/* ── Fix nav overflow so dropdowns aren't clipped ── */
.greedy-nav {
  overflow: visible !important;
}

.greedy-nav .visible-links {
  overflow: visible !important;
  align-items: center;
}

/* ── Dropdown navigation ── */
.masthead__menu-item.has-dropdown {
  position: relative;
}

.nav-parent-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0.25rem 0.6rem;
  cursor: pointer;
  font-size: 0.9em;
  color: inherit;
  white-space: nowrap;
  user-select: none;
  transition: background 0.15s ease;
}

.masthead__menu-item.has-dropdown:hover .nav-parent-label,
.masthead__menu-item.has-dropdown.open .nav-parent-label {
  background: rgba(255, 255, 255, 0.1);
}

.dropdown-arrow {
  font-size: 0.7em;
  transition: transform 0.2s ease;
  display: inline-block;
}

/* Rotate arrow when open */
.masthead__menu-item.has-dropdown:hover .dropdown-arrow,
.masthead__menu-item.has-dropdown.open .dropdown-arrow {
  transform: rotate(-180deg);
}

/* Hidden by default — use opacity + translateY for smooth fade-in */
.dropdown-menu {
  display: block;
  visibility: hidden;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s linear 0.18s;
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  min-width: 160px;
  background: #fff;
  border: 1px solid #ebebeb;
  border-radius: 6px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.09);
  list-style: none;
  padding: 0.3rem 0;
  margin: 0;
  z-index: 9999;
}

/* Show on hover or .open */
.masthead__menu-item.has-dropdown:hover .dropdown-menu,
.masthead__menu-item.has-dropdown.open .dropdown-menu {
  visibility: visible;
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s linear 0s;
}

.dropdown-menu li {
  margin: 0;
}

.dropdown-menu li a {
  display: block;
  padding: 0.35rem 1rem;
  font-size: 0.82em;
  color: #444;
  text-decoration: none;
  white-space: nowrap;
  letter-spacing: 0.01em;
  transition: background 0.12s ease, color 0.12s ease;
}

.dropdown-menu li a:hover {
  background: #f5f5f5;
  color: #111;
  padding-left: 1.2rem;
}

