/* =========================================================================
   FOOTER "MORE LINKS" DISCLOSURE
   -------------------------------------------------------------------------
   Keeps the desktop footer short: Tools + Bots stay visible, while the
   Guides + Countries groups sit inside a closed <details>. The links remain
   real <a href> anchors in the HTML, so crawlers still follow them - they
   are internal links for the hub and country pages, do not delete them.

   Works in both footer variants:
     - .site-footer-compact (bot pages, light or dark via --bbf-* vars)
     - .site-footer          (country hubs, guides, legal - dark theme)
   ========================================================================= */

.footer-more {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.footer-more > summary {
  list-style: none;
  cursor: pointer;
  user-select: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
  border-radius: 3px;
}

.footer-more > summary::-webkit-details-marker { display: none; }

.footer-more > summary::after {
  content: '';
  width: 0.45em;
  height: 0.45em;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: translateY(-25%) rotate(45deg);
  transition: transform 0.2s ease;
}

.footer-more[open] > summary::after { transform: translateY(15%) rotate(-135deg); }

.footer-more > summary:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}

/* When open, the extra groups take their own full-width row */
.footer-more[open] { flex-basis: 100%; }

.footer-more-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 25px;
  margin-top: 8px;
}

/* ---- Compact bot-page footer ---- */
.site-footer-compact .footer-more > summary {
  color: var(--bbf-accent, #007acc);
  font-size: 8px;
  padding: 2px 6px;
}

.site-footer-compact .footer-more > summary:hover {
  background: rgba(0, 122, 204, 0.1);
}

/* ---- Dark hub / guide / legal footer ---- */
.site-footer .footer-more { align-items: flex-start; }

.site-footer .footer-more > summary {
  color: #a78bfa;
  font-size: 0.75rem;
  padding: 0.15rem 0.5rem;
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: 999px;
}

.site-footer .footer-more > summary:hover { background: rgba(167, 139, 250, 0.12); }

.site-footer .footer-more-links {
  justify-content: flex-start;
  gap: 0.5rem 1rem;
}

@media (prefers-reduced-motion: reduce) {
  .footer-more > summary::after { transition: none; }
}
