.rq-nav {
  position: sticky;
  top: 0;
  z-index: var(--rq-z-nav);
  display: flex;
  align-items: center;
  justify-content: space-between;
  isolation: isolate;
  overflow: hidden;
  box-sizing: border-box;
  width: min(var(--rq-wide), calc(100vw - 8rem));
  height: 5rem;
  margin: 0 auto;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.052), rgba(255, 255, 255, 0.01)),
    rgba(0, 0, 0, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.075);
  border-top-color: rgba(255, 255, 255, 0.11);
  border-radius: 0 0 var(--rq-radius-md) var(--rq-radius-md);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.105),
    inset 0 -1px 0 rgba(255, 255, 255, 0.035),
    0 18px 70px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(14px) saturate(145%) contrast(1.05);
  -webkit-backdrop-filter: blur(14px) saturate(145%) contrast(1.05);
  transition:
    background var(--rq-duration) ease,
    border-color var(--rq-duration) ease,
    box-shadow var(--rq-duration) ease,
    backdrop-filter var(--rq-duration) ease;
}

.rq-nav::before,
.rq-nav::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

.rq-nav::before {
  background:
    radial-gradient(circle at 14% 0%, rgba(255, 255, 255, 0.12), transparent 23rem),
    linear-gradient(100deg, rgba(255, 255, 255, 0.055), transparent 42%, rgba(255, 255, 255, 0.035));
  opacity: 0.48;
}

.rq-nav::after {
  background:
    radial-gradient(circle, rgba(255, 255, 255, 0.042) 0 1px, transparent 1.2px) 0 0 / 0.72rem 0.72rem;
  opacity: 0.18;
}

.rq-nav.rq-nav-scrolled,
.rq-inner-page .rq-site-nav {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.018)),
    rgba(3, 4, 6, 0.72);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    inset 0 -1px 0 rgba(255, 255, 255, 0.045),
    0 22px 85px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(var(--rq-blur)) saturate(160%) contrast(1.06);
  -webkit-backdrop-filter: blur(var(--rq-blur)) saturate(160%) contrast(1.06);
}

.rq-brand,
.rq-nav nav {
  display: flex;
  align-items: center;
}

.rq-brand {
  gap: 0.85rem;
  font-family: var(--rq-mono);
  font-size: 1.08rem;
  color: #fff;
  text-decoration: none;
}

.rq-brand-mark {
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 999px;
  background:
    repeating-linear-gradient(18deg, #fff 0 0.18rem, transparent 0.18rem 0.36rem),
    #101010;
  box-shadow: 0 0 0 1px #fff;
}

.rq-nav nav {
  gap: clamp(1rem, 3vw, 2.7rem);
  font-family: var(--rq-mono);
}

.rq-nav nav a {
  position: relative;
  color: #eee;
  text-decoration: none;
}

.rq-nav nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -0.48rem;
  height: 1px;
  transform: scaleX(0);
  transform-origin: left;
  background: #fff;
  transition: transform var(--rq-duration-fast) ease;
}

.rq-nav nav a:hover::after,
.rq-nav nav a.active::after,
.rq-nav nav a:focus-visible::after {
  transform: scaleX(1);
}

.rq-menu-button {
  display: none;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1px solid var(--rq-line);
  border-radius: var(--rq-radius-sm);
  background: rgba(255, 255, 255, 0.045);
  color: #fff;
}

.rq-menu-button span {
  display: block;
  width: 1.25rem;
  height: 1px;
  margin: 0.35rem auto;
  background: currentColor;
}

.rq-button,
.rq-actions a,
.rq-section-head a,
.rq-orbit-about-actions a,
.rq-footer-links a,
.rq-about-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  min-height: 2.8rem;
  padding: 0 1.2rem;
  border: 1px solid var(--rq-line-strong);
  border-radius: var(--rq-radius-xs);
  color: #fff;
  background: rgba(0, 0, 0, 0.36);
  text-decoration: none;
  transition:
    transform var(--rq-duration-fast) ease,
    background var(--rq-duration-fast) ease,
    border-color var(--rq-duration-fast) ease;
}

.rq-button:hover,
.rq-actions a:hover,
.rq-section-head a:hover,
.rq-orbit-about-actions a:hover,
.rq-footer-links a:hover,
.rq-about-actions a:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.12);
  transform: translateY(-2px);
}

.rq-glass {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--rq-glass-border);
  background: var(--rq-glass-bg);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.16),
    inset 0 -1px 0 rgba(255, 255, 255, 0.05),
    0 20px 70px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(var(--rq-blur)) saturate(150%) contrast(1.05);
  -webkit-backdrop-filter: blur(var(--rq-blur)) saturate(150%) contrast(1.05);
}

.rq-glass::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 18% 0%, var(--rq-glass-highlight), transparent 34%),
    linear-gradient(115deg, rgba(255, 255, 255, 0.12), transparent 42%, rgba(255, 255, 255, 0.08));
  opacity: 0.62;
}

.rq-glass::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle, var(--rq-glass-noise) 0 1px, transparent 1.2px) 0 0 / 0.7rem 0.7rem;
  opacity: 0.34;
}

.rq-glass-deep {
  background: var(--rq-glass-bg-deep);
  backdrop-filter: blur(var(--rq-blur-strong)) saturate(135%);
  -webkit-backdrop-filter: blur(var(--rq-blur-strong)) saturate(135%);
}

.rq-project-card,
.rq-blog-row {
  position: relative;
  overflow: hidden;
  color: #fff;
  text-decoration: none;
  background:
    radial-gradient(circle, rgba(255, 255, 255, 0.1) 0 1px, transparent 1px) 0 0 / 0.56rem 0.56rem,
    rgba(12, 12, 12, 0.86);
  transition:
    transform var(--rq-duration-fast) ease,
    border-color var(--rq-duration-fast) ease,
    background var(--rq-duration-fast) ease;
}

.rq-project-card {
  isolation: isolate;
}

.rq-project-card::after {
  content: "";
  position: absolute;
  inset: 1px;
  z-index: -1;
  pointer-events: none;
  border-radius: inherit;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.09), transparent 35%),
    radial-gradient(circle at calc(50% + var(--rq-x, 0) * 30%), calc(50% + var(--rq-y, 0) * 30%), rgba(255, 255, 255, 0.11), transparent 42%);
  opacity: 0;
  transition: opacity var(--rq-duration-fast) ease;
}

.rq-project-card:hover::after,
.rq-project-card:focus-visible::after {
  opacity: 1;
}

.rq-project-card::before,
.rq-blog-row::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  background: linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, 0.18) 48%, transparent 54%);
  transform: translateX(-115%);
}

.rq-project-card:hover::before,
.rq-project-card:focus-visible::before,
.rq-blog-row:hover::before,
.rq-blog-row:focus-visible::before {
  animation: rq-scan 900ms ease forwards;
}

@keyframes rq-scan {
  0% { opacity: 0; transform: translateX(-115%); }
  25% { opacity: 0.55; }
  100% { opacity: 0; transform: translateX(115%); }
}
