/* Shared module nav under /zeri/bencao/ */
.module-nav {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.45rem;
  margin: 0 0 0.85rem;
  max-width: 100%;
}

.module-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.45rem;
  padding: 0.35rem 0.5rem;
  border: 1px solid #e3e8ef;
  border-radius: 12px;
  color: #4b5563;
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  background: #fff;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.module-nav a:hover {
  color: #1a5c38;
  border-color: #c5d9cc;
  background: #f8fbf9;
}

.module-nav a.is-active {
  color: #fff;
  border-color: #1a5c38;
  background: #1a5c38;
  box-shadow: 0 2px 8px rgba(26, 92, 56, 0.18);
}

.related-links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.related-links a {
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.65rem;
  border: 1px solid rgba(26, 92, 56, 0.22);
  border-radius: 999px;
  color: #1a5c38;
  text-decoration: none;
  font-size: 0.86rem;
  font-weight: 600;
  background: #e8f3ec;
}

.related-links a:hover {
  background: #dceee4;
}

.related-empty {
  color: var(--muted);
  font-size: 0.9rem;
}

.visit-block {
  padding: 0.75rem 0;
  border-top: 1px dashed #e3e8ef;
}

.visit-block:first-child {
  padding-top: 0;
  border-top: none;
}

.visit-head {
  font-size: 0.92rem;
  color: #1a5c38;
  margin-bottom: 0.45rem;
  font-weight: 600;
}

.visit-label {
  font-size: 0.78rem;
  color: var(--muted);
  margin: 0.35rem 0 0.15rem;
}

.visit-prose {
  margin: 0;
}

@media (max-width: 520px) {
  .module-nav a {
    min-height: 2.2rem;
    font-size: 0.82rem;
    border-radius: 10px;
  }
}
