/* Shared navigation — makino site system */
/* Include via <link rel="stylesheet" href="/nav.css"> on all pages */

.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  font-family: system-ui, -apple-system, sans-serif;
  font-size: 0.8125rem;
  max-width: 100%;
}

.site-nav-brand {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: 1.125rem;
  color: #111;
  text-decoration: none;
  letter-spacing: -0.01em;
}
.site-nav-brand:hover { color: #000; }

.site-nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav-links a {
  color: #555;
  text-decoration: none;
  transition: color 0.15s;
}
.site-nav-links a:hover { color: #111; }

/* Projects dropdown */
.nav-dropdown {
  position: relative;
}

.nav-dropdown-trigger {
  display: flex;
  align-items: center;
  gap: 3px;
  color: #555;
  cursor: pointer;
  background: none;
  border: none;
  font: inherit;
  padding: 0;
  transition: color 0.15s;
}
.nav-dropdown-trigger:hover { color: #111; }

.nav-dropdown-trigger svg {
  width: 10px;
  height: 10px;
  opacity: 0.5;
  transition: transform 0.2s, opacity 0.2s;
}

.nav-dropdown:hover .nav-dropdown-trigger svg,
.nav-dropdown:focus-within .nav-dropdown-trigger svg {
  transform: rotate(180deg);
  opacity: 0.8;
}

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  min-width: 260px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 6px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0, 0, 0, 0.04);
  padding: 6px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity 0.15s, transform 0.15s, visibility 0.15s;
}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav-dropdown-item {
  display: block;
  padding: 10px 12px;
  border-radius: 4px;
  text-decoration: none;
  color: #111;
  transition: background 0.12s;
}
.nav-dropdown-item:hover {
  background: #f5f5f5;
  color: #111;
}

.nav-dropdown-item-name {
  font-weight: 500;
  font-size: 0.8125rem;
  margin-bottom: 2px;
}
.nav-dropdown-item-desc {
  font-size: 0.7rem;
  color: #888;
  line-height: 1.4;
}

/* Active page indicator */
.site-nav-links a[aria-current="page"],
.nav-dropdown-trigger[aria-current="page"] {
  color: #111;
  font-weight: 500;
}

/* Mobile */
@media (max-width: 600px) {
  .site-nav { padding: 0 16px; }
  .site-nav-links { gap: 16px; }
  .nav-dropdown-menu { right: -16px; min-width: 220px; }
}
