/* ─── ARBITORIA — Navigation ─── */

nav {
  position: fixed; top: 0; left: 0; right: 0;
  display: grid; grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 10px 28px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  backdrop-filter: blur(12px);
  z-index: 100;
  transition: background 0.4s, border-color 0.4s;
  gap: 16px;
}

/* ─── LEFT: LOGO ─── */
.nav-logo {
  display: flex; align-items: center; gap: 8px;
  font-size: 15px; letter-spacing: 0.25em; font-weight: 700;
  color: var(--accent); font-family: var(--font-head);
  white-space: nowrap; cursor: pointer;
  text-decoration: none;
}
.nav-logo svg { width: 22px; height: 22px; transition: transform 0.5s cubic-bezier(0.34,1.56,0.64,1); opacity: 0.85; }
.nav-logo:hover svg { transform: rotate(20deg); opacity: 1; }

/* ─── CENTER: NAV PILLS ─── */
.nav-pills {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: center;
  overflow: visible;
  white-space: nowrap;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  mask-image: none;
  -webkit-mask-image: none;
}
.nav-pills::-webkit-scrollbar { display: none; }

.nav-pill {
  padding: 5px 14px;
  border: 1px solid rgba(184,150,90,0.3);
  border-radius: 999px;
  font-size: 12px;
  font-family: var(--font-body);
  color: var(--muted);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: all 0.25s;
  white-space: nowrap;
  flex-shrink: 0;
  background: linear-gradient(145deg, rgba(255,255,255,0.06), rgba(0,0,0,0.1));
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
}
.nav-pill:hover {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06);
  transform: translateY(-1px);
}
.nav-pill:active {
  transform: translateY(1px);
  box-shadow: inset 2px 2px 6px rgba(0,0,0,0.3), inset -1px -1px 4px rgba(255,255,255,0.03);
}
.nav-pill.active {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(184,150,90,0.08);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
}

.pill-icon svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ─── RIGHT: CONTROLS ─── */
.nav-controls { display: flex; align-items: center; gap: 6px; justify-content: flex-end; }

/* ─── LANG BUTTONS — unified rounded pill ─── */
.lang-bar {
  display: flex; gap: 4px;
  border: none; border-radius: 0; overflow: visible;
  box-shadow: none; background: none;
}
.lang-bar:hover { transform: none; box-shadow: none; }

.lang-btn {
  padding: 5px 10px;
  cursor: pointer;
  color: var(--muted);
  border: 1px solid rgba(184,150,90,0.3);
  border-radius: 999px;
  transition: all 0.25s;
  font-size: 11px;
  letter-spacing: 0.05em;
  user-select: none;
  font-family: var(--font-body);
  background: linear-gradient(145deg, rgba(255,255,255,0.06), rgba(0,0,0,0.1));
  box-shadow: 2px 2px 6px rgba(0,0,0,0.35), -1px -1px 4px rgba(255,255,255,0.04), inset 0 1px 0 rgba(255,255,255,0.05);
}
.lang-btn:last-child { border-right: none; }
.lang-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 3px 3px 8px rgba(0,0,0,0.4), -2px -2px 6px rgba(255,255,255,0.05), inset 0 1px 0 rgba(255,255,255,0.06);
}
.lang-btn:active {
  transform: translateY(1px);
  box-shadow: inset 2px 2px 5px rgba(0,0,0,0.3), inset -1px -1px 3px rgba(255,255,255,0.03);
}
.lang-btn.active {
  background: var(--accent);
  color: var(--bg);
  border-color: var(--accent);
  font-weight: 700;
  box-shadow: 2px 2px 6px rgba(0,0,0,0.35), -1px -1px 4px rgba(184,150,90,0.08), inset 0 1px 0 rgba(255,255,255,0.15);
}

/* ─── LANG TOGGLE ARROW ─── */
.lang-toggle {
  padding: 5px 6px;
  cursor: pointer;
  color: var(--muted);
  border: 1px solid rgba(184,150,90,0.3);
  border-radius: 999px;
  transition: all 0.25s;
  font-size: 11px;
  line-height: 1;
  user-select: none;
  font-family: var(--font-body);
  background: linear-gradient(145deg, rgba(255,255,255,0.06), rgba(0,0,0,0.1));
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 22px;
  box-shadow: 2px 2px 6px rgba(0,0,0,0.35), -1px -1px 4px rgba(255,255,255,0.04), inset 0 1px 0 rgba(255,255,255,0.05);
}
.lang-toggle:hover {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 3px 3px 8px rgba(0,0,0,0.4), -2px -2px 6px rgba(255,255,255,0.05), inset 0 1px 0 rgba(255,255,255,0.06);
}
.lang-toggle:active {
  transform: translateY(1px);
  box-shadow: inset 2px 2px 5px rgba(0,0,0,0.3), inset -1px -1px 3px rgba(255,255,255,0.03);
}
.lang-bar.collapsed .lang-btn:not(.active) {
  display: none;
}

/* ─── MODE TOGGLE — unified rounded pill ─── */
.mode-toggle {
  cursor: pointer;
  font-size: 13px;
  padding: 4px 10px;
  border: 1px solid rgba(184,150,90,0.3);
  border-radius: 999px;
  color: var(--muted);
  transition: all 0.25s;
  user-select: none;
  background: linear-gradient(145deg, rgba(255,255,255,0.06), rgba(0,0,0,0.1));
  box-shadow: 2px 2px 6px rgba(0,0,0,0.35), -1px -1px 4px rgba(255,255,255,0.04), inset 0 1px 0 rgba(255,255,255,0.05);
}
.mode-toggle:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-1px);
  box-shadow: 3px 3px 8px rgba(0,0,0,0.4), -2px -2px 6px rgba(255,255,255,0.05), inset 0 1px 0 rgba(255,255,255,0.06);
}
.mode-toggle:active { transform: translateY(1px); box-shadow: inset 2px 2px 5px rgba(0,0,0,0.3), inset -1px -1px 3px rgba(255,255,255,0.03); }

/* ─── LEGACY ─── */
.nav-back { display: none; }
